Skip to content
This repository was archived by the owner on Apr 3, 2024. It is now read-only.

Commit c75494c

Browse files
chore: Replace it.only with it in test-install.ts (#380)
1 parent f24a466 commit c75494c

File tree

2 files changed

+22
-24
lines changed

2 files changed

+22
-24
lines changed

src/agent/debuglet.ts

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -276,8 +276,7 @@ export class Debuglet extends EventEmitter {
276276
const stat = promisify(fs.stat);
277277

278278
try {
279-
await stat(
280-
path.join(that.config.workingDirectory, 'package.json'));
279+
await stat(path.join(that.config.workingDirectory, 'package.json'));
281280
} catch (err) {
282281
that.logger.error('No package.json located in working directory.');
283282
that.emit('initError', new Error('No package.json found.'));
@@ -292,8 +291,8 @@ export class Debuglet extends EventEmitter {
292291

293292
let fileStats: scanner.ScanResults;
294293
try {
295-
fileStats = await scanner.scan(
296-
!id, that.config.workingDirectory, /.js$|.map$/);
294+
fileStats =
295+
await scanner.scan(!id, that.config.workingDirectory, /.js$|.map$/);
297296
} catch (err) {
298297
that.logger.error('Error scanning the filesystem.', err);
299298
that.emit('initError', err);

system-test/test-install.ts

Lines changed: 19 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -145,26 +145,25 @@ describe('Installation', () => {
145145

146146
describe('When used with Typescript code', () => {
147147
TS_CODE_ARRAY.forEach((sample) => {
148-
it.only(
149-
`should install and work with code that ${sample.description}`,
150-
async function() {
151-
this.timeout(TIMEOUT_MS);
152-
assert(installDir);
153-
const srcDir = path.join(installDir!, 'src');
154-
await mkdirP(srcDir);
155-
await writeFileP(path.join(srcDir, INDEX_TS), sample.code, 'utf-8');
156-
await spawnP(
157-
'npm', ['install', '--save-dev', 'gts', '[email protected]'],
158-
{cwd: installDir, stdio}, log);
159-
await spawnP(
160-
'gts', ['init', '--yes'], {cwd: installDir, stdio}, log);
161-
await spawnP(
162-
'npm', ['run', 'compile'], {cwd: installDir, stdio}, log);
163-
const buildDir = path.join(installDir!, 'build');
164-
await spawnP(
165-
'node', [path.join(buildDir, 'src', INDEX_JS)],
166-
{cwd: installDir, stdio}, log);
167-
});
148+
it(`should install and work with code that ${sample.description}`,
149+
async function() {
150+
this.timeout(TIMEOUT_MS);
151+
assert(installDir);
152+
const srcDir = path.join(installDir!, 'src');
153+
await mkdirP(srcDir);
154+
await writeFileP(path.join(srcDir, INDEX_TS), sample.code, 'utf-8');
155+
await spawnP(
156+
'npm', ['install', '--save-dev', 'gts', '[email protected]'],
157+
{cwd: installDir, stdio}, log);
158+
await spawnP(
159+
'gts', ['init', '--yes'], {cwd: installDir, stdio}, log);
160+
await spawnP(
161+
'npm', ['run', 'compile'], {cwd: installDir, stdio}, log);
162+
const buildDir = path.join(installDir!, 'build');
163+
await spawnP(
164+
'node', [path.join(buildDir, 'src', INDEX_JS)],
165+
{cwd: installDir, stdio}, log);
166+
});
168167
});
169168
});
170169

0 commit comments

Comments
 (0)