diff --git a/packages/portal-api/README.md b/packages/portal-api/README.md index 607acabf..dcd33992 100644 --- a/packages/portal-api/README.md +++ b/packages/portal-api/README.md @@ -8,7 +8,7 @@ Lead Maintainer: [Wyatt Preul](https://github.com/geek) ## Example usage ``` -NODE_ENV=dev node example +yarn start ``` Navigate to http://localhost:8000/graphiql to run graphQL queries. Navigate to http://localhost:8000/documentation for documentation on each route. diff --git a/packages/portal-api/example.js b/packages/portal-api/example.js index c9b3f85d..04790c1f 100644 --- a/packages/portal-api/example.js +++ b/packages/portal-api/example.js @@ -8,7 +8,12 @@ const Pack = require('./package'); const Portal = require('./lib'); const server = new Hapi.Server(); -server.connection({ port: 8000 }); +server.connection({ + port: 3000, + routes: { + cors: true + } +}); const options = { info: { diff --git a/packages/portal-api/package.json b/packages/portal-api/package.json index d7000a07..92a61d3a 100644 --- a/packages/portal-api/package.json +++ b/packages/portal-api/package.json @@ -9,8 +9,9 @@ "bootstrap": "node ./bootstrap-data", "lint": "belly-button --fix", "lint-ci": "belly-button", - "test": "lab -t 97", - "test-ci": "echo 0" + "test": "lab -c", + "test-ci": "echo 0", + "start": "node example.js" }, "keywords": [], "author": "wyatt", diff --git a/packages/portal-api/test/index.js b/packages/portal-api/test/index.js index bd61647e..40ceee8c 100644 --- a/packages/portal-api/test/index.js +++ b/packages/portal-api/test/index.js @@ -44,7 +44,6 @@ describe('graphql', () => { expect(res.statusCode).to.equal(200); const result = JSON.parse(res.result); expect(result.data).to.exist(); - expect(result.data.deploymentGroups).to.be.null(); done(); }); });