Skip to content

Commit dcc2559

Browse files
trace or whatever
1 parent d8acbc7 commit dcc2559

File tree

2 files changed

+18
-7
lines changed

2 files changed

+18
-7
lines changed

packages/compass-e2e-tests/helpers/compass.ts

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -168,9 +168,16 @@ export class Compass {
168168

169169
for (const [k, v] of Object.entries(Commands)) {
170170
this.browser.addCommand(k, (...args) => {
171+
// kinda interesting
172+
console.log('adding list of commands and doing k[v]: ', k);
171173
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
172174
// @ts-ignore
173-
return v(browser, ...args);
175+
return (() => {
176+
console.log('I am running command k ', k);
177+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
178+
// @ts-ignore
179+
return v(this.browser, ...args);
180+
})();
174181
});
175182
}
176183

@@ -449,6 +456,8 @@ async function getCompassExecutionParameters(): Promise<{
449456
const binary = testPackagedApp
450457
? getCompassBinPath(await getCompassBuildMetadata())
451458
: ELECTRON_PATH;
459+
console.log('looks like the binary is ', binary);
460+
console.log('btw test packaged app is ', testPackagedApp);
452461
return { testPackagedApp, binary };
453462
}
454463

@@ -674,8 +683,10 @@ async function startCompassElectron(
674683
...wdioOptions,
675684
};
676685

677-
debug('Starting compass via webdriverio with the following configuration:');
678-
debug(JSON.stringify(options, null, 2));
686+
console.log(
687+
'Starting compass via webdriverio with the following configuration:'
688+
);
689+
console.log(JSON.stringify(options, null, 2));
679690

680691
let browser: CompassBrowser;
681692

@@ -831,6 +842,7 @@ export async function startBrowser(
831842
`${atlasCloudExternalUrl}/v2/${atlasCloudExternalProjectId}#/explorer`
832843
);
833844
} else {
845+
console.log('navigating to sandbox url: ', context.sandboxUrl);
834846
await browser.navigateTo(context.sandboxUrl);
835847
}
836848

packages/compass-e2e-tests/tests/no-network-traffic.test.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,9 @@ describe('networkTraffic: false / Isolated Edition', function () {
5858
const outfile = path.join(tmpdir, 'strace-out.log');
5959
async function wrapBinary(binary: string): Promise<string> {
6060
const wrapperFile = path.join(tmpdir, 'wrap.sh');
61-
await fs.writeFile(
62-
wrapperFile,
63-
`#!/bin/bash\nulimit -c 0; '${binary}' "$@"\n`
64-
);
61+
const str = `#!/bin/bash\nulimit -c 0; '${binary}' "$@"\n`;
62+
console.log('contents of wrapped file will be ', str);
63+
await fs.writeFile(wrapperFile, str);
6564
await fs.chmod(wrapperFile, 0o755);
6665
return wrapperFile;
6766
}

0 commit comments

Comments
 (0)