From 890b19de70d68c42693fb6c45ab28bbef5e6e59e Mon Sep 17 00:00:00 2001 From: Jason Dobry Date: Mon, 9 Jan 2017 07:41:37 -0800 Subject: [PATCH] Update README. --- README.md | 84 +++++++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 79 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 97fd745519f..9b209f8f621 100644 --- a/README.md +++ b/README.md @@ -144,6 +144,10 @@ on Google Cloud Platform. npm install + or + + yarn install + 1. Run the sample: node sample_file.js [args]... @@ -151,6 +155,15 @@ on Google Cloud Platform. ### How to run the tests 1. Read the [Contributing Guide][contrib]. +1. You must install dependencies at the root of the `nodejs-docs-samples` +directory. You can do so with `yarn` or `npm`: + + npm install + + or + + yarn install + 1. In a terminal, start Redis: redis-server @@ -163,22 +176,81 @@ on Google Cloud Platform. npm test - or with coverage: + or + + yarn test + + With code coverage: + + npm run cover + + or - npm run coverage + yarn run cover 1. Then run the system tests from the root of the project: npm run system-test - or with coverage: + or + + yarn run system-test + + With code coverage: npm run system-cover -1. Or run all the tests at once with coverage: + or + + yarn run system-cover + +1. Or run all the tests at once: + + npm run all-test + + or + + yarn run all-test + + With code coverage: npm run all-cover + or + + yarn run all-cover + +### Run the tests for a single sample + +1. You must install dependencies at the root of the `nodejs-docs-samples` +directory. You can do so with `yarn` or `npm`: + + npm install + + or + + yarn install + +1. Change directory to one of the sample folders, e.g. `bigquery`: + + cd bigquery/ + +1. Run the tests (check the `package.json` file): + + npm test + + or + + yarn test + + or + + npm run system-test + + or + + yarn run system-test + ## Client libraries ### Google Cloud Platform logoGoogle Cloud Node.js client library @@ -190,7 +262,9 @@ The recommended, idiomatic client for Google Cloud Platform services. ### Google logoGoogle API Node.js client library -An older Node.js client library for making REST requests to Google APIs. +An older Node.js client library for making REST requests to Google APIs. Use +this for Google Cloud APIs that are not yet supported by the Google Cloud +Node.js client library. * [Documentation](http://google.github.io/google-api-nodejs-client/) * [Source code](https://github.com/google/google-api-nodejs-client)