Skip to content
This repository was archived by the owner on Dec 15, 2022. It is now read-only.

Commit 51084ab

Browse files
replace every context with describe
1 parent 4e5df82 commit 51084ab

File tree

1 file changed

+44
-44
lines changed

1 file changed

+44
-44
lines changed

test/github-package.test.js

Lines changed: 44 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -209,15 +209,15 @@ describe.only('GithubPackage', function() {
209209
}
210210
}
211211

212-
context('with no project, state, or active pane', function() {
212+
describe('with no project, state, or active pane', function() {
213213
beforeEach(async function() {
214214
await contextUpdateAfter(githubPackage, () => githubPackage.activate());
215215
});
216216

217217
usesUndeterminedRepositoryContext();
218218
});
219219

220-
context('with only 1 project', function() {
220+
describe('with only 1 project', function() {
221221
let workdirPath;
222222
beforeEach(async function() {
223223
workdirPath = await cloneRepository('three-files');
@@ -229,7 +229,7 @@ describe.only('GithubPackage', function() {
229229
usesProjectContextFromPath(workdirPath);
230230
});
231231

232-
context('with only projects', function() {
232+
describe('with only projects', function() {
233233
let workdirPath1, workdirPath2, nonRepositoryPath;
234234
beforeEach(async function() {
235235
([workdirPath1, workdirPath2, nonRepositoryPath] = await Promise.all([
@@ -251,7 +251,7 @@ describe.only('GithubPackage', function() {
251251
});
252252
});
253253

254-
context('with projects and an active pane', function() {
254+
describe('with projects and an active pane', function() {
255255
let workdirPath1, workdirPath2;
256256
beforeEach(async function() {
257257
([workdirPath1, workdirPath2] = await Promise.all([
@@ -267,7 +267,7 @@ describe.only('GithubPackage', function() {
267267
usesActivePaneContextFromPath(workdirPath2);
268268
});
269269

270-
context('with projects and state', function() {
270+
describe('with projects and state', function() {
271271
let workdirPath1, workdirPath2, workdirPath3;
272272
beforeEach(async function() {
273273
([workdirPath1, workdirPath2, workdirPath3] = await Promise.all([
@@ -291,7 +291,7 @@ describe.only('GithubPackage', function() {
291291
});
292292
});
293293

294-
context('with projects, state, and an active pane', function() {
294+
describe('with projects, state, and an active pane', function() {
295295
let workdirPath1, workdirPath2;
296296
beforeEach(async function() {
297297
([workdirPath1, workdirPath2] = await Promise.all([
@@ -309,7 +309,7 @@ describe.only('GithubPackage', function() {
309309
usesActivePaneContextFromPath(workdirPath2);
310310
});
311311

312-
context('with 1 project and state', function() {
312+
describe('with 1 project and state', function() {
313313
let workdirPath1, workdirPath2;
314314
beforeEach(async function() {
315315
([workdirPath1, workdirPath2] = await Promise.all([
@@ -326,7 +326,7 @@ describe.only('GithubPackage', function() {
326326
usesProjectContextFromPath(workdirPath1);
327327
});
328328

329-
context('with showOnStartup and no config file', function() {
329+
describe('with showOnStartup and no config file', function() {
330330
let confFile;
331331
beforeEach(async function() {
332332
confFile = path.join(configDirPath, 'github.cson');
@@ -343,7 +343,7 @@ describe.only('GithubPackage', function() {
343343
assertFileExists('writes a config', confFile);
344344
});
345345

346-
context('with showOnStartup and no config file', function() {
346+
describe('with showOnStartup and no config file', function() {
347347
let confFile;
348348
beforeEach(async function() {
349349
confFile = path.join(configDirPath, 'github.cson');
@@ -360,7 +360,7 @@ describe.only('GithubPackage', function() {
360360
assertFileExists('writes a config', confFile);
361361
});
362362

363-
context('when it\'s not the first run for new projects', function() {
363+
describe('when it\'s not the first run for new projects', function() {
364364
let confFile;
365365
beforeEach(async function() {
366366
confFile = path.join(configDirPath, 'github.cson');
@@ -375,7 +375,7 @@ describe.only('GithubPackage', function() {
375375
assertFileExists('has a config', confFile);
376376
});
377377

378-
context('when it\'s not the first run for existing projects', function() {
378+
describe('when it\'s not the first run for existing projects', function() {
379379
let confFile;
380380
beforeEach(async function() {
381381
confFile = path.join(configDirPath, 'github.cson');
@@ -456,7 +456,7 @@ describe.only('GithubPackage', function() {
456456
atomEnv.destroy();
457457
});
458458

459-
context('with no projects', function() {
459+
describe('with no projects', function() {
460460
beforeEach(async function() {
461461
await contextUpdateAfter(githubPackage, () => githubPackage.activate());
462462
});
@@ -466,7 +466,7 @@ describe.only('GithubPackage', function() {
466466
});
467467
});
468468

469-
context('with existing projects', function() {
469+
describe('with existing projects', function() {
470470
let workdirPath1, workdirPath2, workdirPath3;
471471
beforeEach(async function() {
472472
([workdirPath1, workdirPath2, workdirPath3] = await Promise.all([
@@ -487,7 +487,7 @@ describe.only('GithubPackage', function() {
487487
assert.isFalse(contextPool.getContext(workdirPath3).isPresent());
488488
});
489489

490-
context('when opening a new project', function() {
490+
describe('when opening a new project', function() {
491491
beforeEach(async function() {
492492
await contextUpdateAfter(githubPackage, () => project.setPaths([workdirPath1, workdirPath2, workdirPath3]));
493493
});
@@ -497,7 +497,7 @@ describe.only('GithubPackage', function() {
497497
});
498498
});
499499

500-
context('when removing a project', function() {
500+
describe('when removing a project', function() {
501501
beforeEach(async function() {
502502
await contextUpdateAfter(githubPackage, () => project.setPaths([workdirPath1]));
503503
});
@@ -507,7 +507,7 @@ describe.only('GithubPackage', function() {
507507
});
508508
});
509509

510-
context('when removing all projects', function() {
510+
describe('when removing all projects', function() {
511511
beforeEach(async function() {
512512
await contextUpdateAfter(githubPackage, () => project.setPaths([]));
513513
});
@@ -521,7 +521,7 @@ describe.only('GithubPackage', function() {
521521
});
522522
});
523523

524-
context('when an active pane is opened', function() {
524+
describe('when an active pane is opened', function() {
525525
beforeEach(async function() {
526526
await contextUpdateAfter(githubPackage, () => workspace.open(path.join(workdirPath2, 'b.txt')));
527527
});
@@ -533,7 +533,7 @@ describe.only('GithubPackage', function() {
533533
});
534534
});
535535

536-
context('with non-repository, no-conflict, and in-progress merge-conflict projects', function() {
536+
describe('with non-repository, no-conflict, and in-progress merge-conflict projects', function() {
537537
let nonRepositoryPath, workdirNoConflict, workdirMergeConflict;
538538
const remainingMarkerCount = 3;
539539

@@ -566,7 +566,7 @@ describe.only('GithubPackage', function() {
566566
resolutionMergeConflict.reportMarkerCount('modified-on-both-ours.txt', remainingMarkerCount);
567567
});
568568

569-
context('when opening an in-progress merge-conflict project', function() {
569+
describe('when opening an in-progress merge-conflict project', function() {
570570
let resolutionMergeConflict;
571571
beforeEach(async function() {
572572
await workspace.open(path.join(workdirMergeConflict, 'modified-on-both-ours.txt'));
@@ -583,7 +583,7 @@ describe.only('GithubPackage', function() {
583583
});
584584
});
585585

586-
context('when opening a no-conflict repository project', function() {
586+
describe('when opening a no-conflict repository project', function() {
587587
let resolutionNoConflict;
588588
beforeEach(async function() {
589589
await workspace.open(path.join(workdirNoConflict, 'b.txt'));
@@ -596,7 +596,7 @@ describe.only('GithubPackage', function() {
596596
hasActiveResolutionProgress(false);
597597
});
598598

599-
context('when opening a non-repository project', function() {
599+
describe('when opening a non-repository project', function() {
600600
beforeEach(async function() {
601601
await workspace.open(path.join(nonRepositoryPath, 'c.txt'));
602602
await githubPackage.scheduleActiveContextUpdate();
@@ -606,7 +606,7 @@ describe.only('GithubPackage', function() {
606606
});
607607
});
608608

609-
context('with projects, state, and an active pane', function() {
609+
describe('with projects, state, and an active pane', function() {
610610
let workdirPath1, workdirPath2, workdirPath3;
611611
beforeEach(async function() {
612612
([workdirPath1, workdirPath2, workdirPath3] = await Promise.all([
@@ -625,7 +625,7 @@ describe.only('GithubPackage', function() {
625625
usesActivePaneContextFromPath(workdirPath2);
626626
});
627627

628-
context('with 1 project and state', function() {
628+
describe('with 1 project and state', function() {
629629
let workdirPath1, workdirPath2;
630630
beforeEach(async function() {
631631
([workdirPath1, workdirPath2] = await Promise.all([
@@ -642,7 +642,7 @@ describe.only('GithubPackage', function() {
642642
usesProjectContextFromPath(workdirPath1);
643643
});
644644

645-
context('with projects and state', function() {
645+
describe('with projects and state', function() {
646646
let workdirPath1, workdirPath2;
647647
beforeEach(async function() {
648648
([workdirPath1, workdirPath2] = await Promise.all([
@@ -661,7 +661,7 @@ describe.only('GithubPackage', function() {
661661
});
662662
});
663663

664-
context('with a non-repository project', function() {
664+
describe('with a non-repository project', function() {
665665
let nonRepositoryPath;
666666
beforeEach(async function() {
667667
nonRepositoryPath = await getTempDir();
@@ -686,7 +686,7 @@ describe.only('GithubPackage', function() {
686686
});
687687
});
688688

689-
context('with an active pane in a non-repository project', function() {
689+
describe('with an active pane in a non-repository project', function() {
690690
beforeEach(async function() {
691691
const nonRepositoryPath = await fs.realpath(temp.mkdirSync());
692692
const workdir = await cloneRepository('three-files');
@@ -703,7 +703,7 @@ describe.only('GithubPackage', function() {
703703
});
704704
});
705705

706-
context('with multiple pane items', function() {
706+
describe('with multiple pane items', function() {
707707
let workdirPath1, workdirPath2;
708708

709709
if (useLegacyPanels) {
@@ -727,7 +727,7 @@ describe.only('GithubPackage', function() {
727727
usesActivePaneContextFromPath(workdirPath1);
728728
});
729729

730-
context('with an active context', function() {
730+
describe('with an active context', function() {
731731
let workdirPath1, workdirPath2;
732732
beforeEach(async function() {
733733
([workdirPath1, workdirPath2] = await Promise.all([
@@ -747,7 +747,7 @@ describe.only('GithubPackage', function() {
747747
});
748748
});
749749

750-
context('with a repository project\'s subdirectory', function() {
750+
describe('with a repository project\'s subdirectory', function() {
751751
let workdirPath;
752752
beforeEach(async function() {
753753
workdirPath = await cloneRepository('three-files');
@@ -762,7 +762,7 @@ describe.only('GithubPackage', function() {
762762
});
763763
});
764764

765-
context('with a repository project', function() {
765+
describe('with a repository project', function() {
766766
let workdirPath;
767767
beforeEach(async function() {
768768
workdirPath = await cloneRepository('three-files');
@@ -773,7 +773,7 @@ describe.only('GithubPackage', function() {
773773

774774
assertContextIsInPoolAndPresent('creates a context for the project', workdirPath);
775775

776-
context('when the repository is destroyed', function() {
776+
describe('when the repository is destroyed', function() {
777777
beforeEach(function() {
778778
const repository = contextPool.getContext(workdirPath).getRepository();
779779
repository.destroy();
@@ -785,7 +785,7 @@ describe.only('GithubPackage', function() {
785785
});
786786
});
787787

788-
context('with a symlinked repository project', function() {
788+
describe('with a symlinked repository project', function() {
789789
beforeEach(async function() {
790790
if (process.platform === 'win32') {
791791
this.skip();
@@ -851,7 +851,7 @@ describe.only('GithubPackage', function() {
851851
atomEnv.destroy();
852852
});
853853

854-
context('with a non-repository project', function() {
854+
describe('with a non-repository project', function() {
855855
let nonRepositoryPath;
856856
beforeEach(async function() {
857857
nonRepositoryPath = await getTempDir();
@@ -920,7 +920,7 @@ describe.only('GithubPackage', function() {
920920
atomEnv.destroy();
921921
});
922922

923-
context('with an existing project', function() {
923+
describe('with an existing project', function() {
924924
let existingPath, sourcePath;
925925

926926
// Setup files and the GitHub Package
@@ -944,7 +944,7 @@ describe.only('GithubPackage', function() {
944944
});
945945
});
946946

947-
context('with no projects', function() {
947+
describe('with no projects', function() {
948948
let newPath, sourcePath, originalRepo;
949949

950950
// Setup files and the GitHub Package
@@ -1026,7 +1026,7 @@ describe.only('GithubPackage', function() {
10261026
atomEnv.destroy();
10271027
});
10281028

1029-
context('when called before the initial render', function() {
1029+
describe('when called before the initial render', function() {
10301030
let item;
10311031
beforeEach(function() {
10321032
item = githubPackage.createCommitPreviewStub({uri: 'atom-github://commit-preview'});
@@ -1039,7 +1039,7 @@ describe.only('GithubPackage', function() {
10391039
createsStubCommitPreviewItem(item);
10401040
});
10411041

1042-
context('when called after the initial render', function() {
1042+
describe('when called after the initial render', function() {
10431043
let item;
10441044
beforeEach(function() {
10451045
githubPackage.controller = Symbol('controller');
@@ -1107,7 +1107,7 @@ describe.only('GithubPackage', function() {
11071107
atomEnv.destroy();
11081108
});
11091109

1110-
context('when called before the initial render', function() {
1110+
describe('when called before the initial render', function() {
11111111
let item;
11121112
beforeEach(function() {
11131113
item = githubPackage.createCommitDetailStub({uri: 'atom-github://commit-detail?workdir=/home&sha=1234'});
@@ -1120,7 +1120,7 @@ describe.only('GithubPackage', function() {
11201120
createsStubCommitDetailItem(item);
11211121
});
11221122

1123-
context('when called after the initial render', function() {
1123+
describe('when called after the initial render', function() {
11241124
let item;
11251125
beforeEach(function() {
11261126
githubPackage.controller = Symbol('controller');
@@ -1135,7 +1135,7 @@ describe.only('GithubPackage', function() {
11351135
});
11361136
});
11371137

1138-
context('with repository projects', function() {
1138+
describe('with repository projects', function() {
11391139
let atomEnv, githubPackage;
11401140
let workspace, project, commands, notificationManager;
11411141
let tooltips, deserializers, config, keymaps, styles;
@@ -1237,7 +1237,7 @@ describe.only('GithubPackage', function() {
12371237
atomEnv.destroy();
12381238
});
12391239

1240-
context('when a file change is made outside Atom in workspace 1', function() {
1240+
describe('when a file change is made outside Atom in workspace 1', function() {
12411241
beforeEach(function() {
12421242
if (process.platform === 'linux') {
12431243
this.skip();
@@ -1249,7 +1249,7 @@ describe.only('GithubPackage', function() {
12491249
refreshesRepositories(repository1, atomGitRepository1);
12501250
});
12511251

1252-
context('when a file change is made outside Atom in workspace 2', function() {
1252+
describe('when a file change is made outside Atom in workspace 2', function() {
12531253
beforeEach(function() {
12541254
if (process.platform === 'linux') {
12551255
this.skip();
@@ -1261,15 +1261,15 @@ describe.only('GithubPackage', function() {
12611261
refreshesRepositories(repository2, atomGitRepository2);
12621262
});
12631263

1264-
context('when a commit is made outside Atom in workspace 1', function() {
1264+
describe('when a commit is made outside Atom in workspace 1', function() {
12651265
beforeEach(async function() {
12661266
await repository1.git.exec(['commit', '-am', 'commit in repository1']);
12671267
});
12681268

12691269
refreshesRepositories(repository1, atomGitRepository1);
12701270
});
12711271

1272-
context('when a commit is made outside Atom in workspace 2', function() {
1272+
describe('when a commit is made outside Atom in workspace 2', function() {
12731273
beforeEach(async function() {
12741274
await repository2.git.exec(['commit', '-am', 'commit in repository2']);
12751275
});

0 commit comments

Comments
 (0)