fix(core): update
This commit is contained in:
30
test/test.ts
30
test/test.ts
@ -1,8 +1,26 @@
|
||||
import { expect, tap } from 'tapbundle'
|
||||
import * as docean from '../ts/index'
|
||||
import { expect, tap } from '@pushrocks/tapbundle';
|
||||
import { Qenv } from '@pushrocks/qenv';
|
||||
|
||||
tap.test('first test', async () => {
|
||||
console.log(docean.standardExport)
|
||||
})
|
||||
const testQenv = new Qenv('./', './.nogit/');
|
||||
|
||||
tap.start()
|
||||
import * as digitalocean from '../ts/index';
|
||||
|
||||
let testAccount: digitalocean.DigitalOceanAccount;
|
||||
let testDroplet: digitalocean.DigitalOceanDroplet;
|
||||
|
||||
tap.test('should create a valid account instance', async () => {
|
||||
testAccount = new digitalocean.DigitalOceanAccount(process.env.DO_API_TOKEN);
|
||||
expect(testAccount).to.be.instanceOf(digitalocean.DigitalOceanAccount);
|
||||
});
|
||||
|
||||
tap.test('should be able to create a droplet', async () => {
|
||||
await digitalocean.DigitalOceanDroplet.createDroplet({
|
||||
account: testAccount,
|
||||
name: 'mydroplet1',
|
||||
image: 'ubuntu-18-04-x64',
|
||||
region: 'fra1',
|
||||
size: 's-1vcpu-1gb'
|
||||
});
|
||||
});
|
||||
|
||||
tap.start();
|
||||
|
Reference in New Issue
Block a user