Skip to content
This repository has been archived by the owner on Jul 13, 2023. It is now read-only.

refactor(samples): convert sample tests from ava to mocha #56

Merged
merged 2 commits into from
Nov 21, 2018
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 5 additions & 7 deletions samples/system-test/quickstart.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,15 @@ const storage = new Storage();
const bucketName = `asset-nodejs-${uuid.v4()}`;
const bucket = storage.bucket(bucketName);

test.describe('quickstart sample tests', () => {
test.before(tools.checkCredentials);
test.before(async () => {
describe('Quickstart sample tests', () => {
before(async () => {
tools.checkCredentials();
await bucket.create();
});

test.after(async () => {
await bucket.delete();
});
after(async () => await bucket.delete());

test.it('should export assets to specified path', async () => {
it('should export assets to specified path', async () => {
const dumpFilePath = util.format('gs://%s/my-assets.txt', bucketName);
await tools.runAsyncWithIO(`${cmd} export-assets ${dumpFilePath}`, cwd);
const file = await bucket.file('my-assets.txt');
Expand Down