Skip to content

Commit 7a5aefc

Browse files
committed
Test for #490
1 parent ad4c54f commit 7a5aefc

File tree

1 file changed

+26
-0
lines changed

1 file changed

+26
-0
lines changed

test/docker.js

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,32 @@ describe("#docker", function() {
110110
src: ['Dockerfile']
111111
}, {}, handler);
112112
});
113+
114+
it("should throw error while building image using ENOENT files", function(done) {
115+
this.timeout(60000);
116+
117+
function handler(err, stream) {
118+
expect(err).not.to.be.null;
119+
expect(stream).to.be.undefined;
120+
121+
if(stream !== undefined) {
122+
stream.pipe(process.stdout, {
123+
end: true
124+
});
125+
126+
stream.on('end', function() {
127+
done();
128+
});
129+
} else {
130+
done();
131+
}
132+
}
133+
134+
docker.buildImage({
135+
context: __dirname,
136+
src: ['Dockerfile2']
137+
}, {}, handler);
138+
});
113139
});
114140

115141

0 commit comments

Comments
 (0)