-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add test for installing starter using 'gatsby new'
- Loading branch information
1 parent
885d326
commit ae6e01a
Showing
1 changed file
with
14 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import test from 'ava' | ||
import fs from 'fs-extra' | ||
import Promise from 'bluebird' | ||
const remove = Promise.promisify(fs.remove) | ||
const tmpdir = require('os').tmpdir() | ||
|
||
import { gatsby } from '../support' | ||
|
||
test('calling gatsby new succesfully creates new site from default starter', async t => { | ||
await remove(`${tmpdir}/gatsby-default-starter`) | ||
const noArgs = await gatsby(['new', `${tmpdir}/tmp/gatsby-default-starter`]) | ||
console.log(noArgs) | ||
t.is(noArgs.code, 0) | ||
}) |