mirror of
https://github.com/valentineus/simple-container.git
synced 2025-06-03 05:13:34 +03:00
Changed structure of the test
This commit is contained in:
parent
ad3924b45e
commit
0b1fbd32c0
@ -3,14 +3,27 @@ import { assert } from 'chai';
|
||||
import Containers from '../lib/index';
|
||||
|
||||
describe('simple-container:', () => {
|
||||
it('simple', (done) => {
|
||||
var container = null;
|
||||
|
||||
before((done) => {
|
||||
var containers = new Containers();
|
||||
var image = 'hello-world:latest';
|
||||
|
||||
containers.create(image).then(container => {
|
||||
if (container) {
|
||||
done();
|
||||
}
|
||||
containers.create(image).then(item => {
|
||||
container = item;
|
||||
done();
|
||||
});
|
||||
});
|
||||
|
||||
after((done) => {
|
||||
container.stop(() => {
|
||||
container.remove(() => {
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
it('simple', () => {
|
||||
assert.isString(container.id);
|
||||
});
|
||||
});
|
Loading…
x
Reference in New Issue
Block a user