diff --git a/video-intelligence/system-test/analyze.test.js b/video-intelligence/system-test/analyze.test.js index 1e48c54aed..a036efcef3 100644 --- a/video-intelligence/system-test/analyze.test.js +++ b/video-intelligence/system-test/analyze.test.js @@ -18,23 +18,25 @@ 'use strict'; require(`../../system-test/_setup`); +const path = require(`path`); const cmd = `node analyze.js`; +const cwd = path.join(__dirname, `..`); // analyze_faces test(`should analyze faces`, async (t) => { - const output = await runAsync(`${cmd} faces gs://nodejs-docs-samples/video/google_gmail.mp4`); + const output = await runAsync(`${cmd} faces gs://nodejs-docs-samples/video/google_gmail.mp4`, cwd); t.regex(output, /Thumbnail size: \d+/); }); // analyze_labels test(`should analyze labels`, async (t) => { - const output = await runAsync(`${cmd} labels gs://nodejs-docs-samples/video/cat.mp4`); + const output = await runAsync(`${cmd} labels gs://nodejs-docs-samples/video/cat.mp4`, cwd); t.regex(output, /Label description: Whiskers/); }); // analyze_shots test(`should analyze shots`, async (t) => { - const output = await runAsync(`${cmd} shots gs://nodejs-docs-samples/video/gbike_dinosaur.mp4`); + const output = await runAsync(`${cmd} shots gs://nodejs-docs-samples/video/gbike_dinosaur.mp4`, cwd); t.regex(output, /Scene 0:/); });