Skip to content

Commit a540f83

Browse files
add 'because' statements
1 parent f3b2df7 commit a540f83

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/test/cli.build.test.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,9 @@ describe('Dev Containers CLI', function () {
7878
const buildWithoutCacheCommand = `${commandBase} --image-name ${nonCachedImageName} --no-cache`;
7979

8080
// Act
81-
await shellExec(buildCommand); // initial run of command
82-
await shellExec(cachedBuildCommand); // rerun command using cache
83-
await shellExec(buildWithoutCacheCommand); // rerun command without cache
81+
await shellExec(buildCommand);
82+
await shellExec(cachedBuildCommand);
83+
await shellExec(buildWithoutCacheCommand);
8484

8585
// Assert
8686
const originalImageInspectCommandResult = await shellExec(`docker inspect ${originalImageName}`);
@@ -95,8 +95,8 @@ describe('Dev Containers CLI', function () {
9595
const cachedImageLayers: string[] = cachedImageDetails[0].RootFS.Layers;
9696
const nonCachedImageLayers: string[] = noCacheImageDetails[0].RootFS.Layers;
9797

98-
assert.deepEqual(originalImageLayers, cachedImageLayers);
99-
assert.notDeepEqual(cachedImageLayers, nonCachedImageLayers);
98+
assert.deepEqual(originalImageLayers, cachedImageLayers, 'because they were built csequentially and should have used caching');
99+
assert.notDeepEqual(cachedImageLayers, nonCachedImageLayers, 'because we passed the --no-cache argument disabling caching');
100100
});
101101

102102
it('should fail with "not found" error when config is not found', async () => {

0 commit comments

Comments
 (0)