From abe65bf4fc58df18077c4b2aa8b8ac3221d62344 Mon Sep 17 00:00:00 2001 From: Alexander Fenster Date: Wed, 13 Nov 2019 14:58:47 -0800 Subject: [PATCH] system tests --- synth.metadata | 2 +- synth.py | 4 ++++ system-test/fixtures/sample/src/index.js | 2 +- system-test/fixtures/sample/src/index.ts | 2 +- 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/synth.metadata b/synth.metadata index d5ff5634..e5fabf3f 100644 --- a/synth.metadata +++ b/synth.metadata @@ -1,5 +1,5 @@ { - "updateTime": "2019-11-13T22:41:44.289221Z", + "updateTime": "2019-11-13T22:57:28.867681Z", "sources": [ { "git": { diff --git a/synth.py b/synth.py index cd7f7eba..6a5ef6ef 100644 --- a/synth.py +++ b/synth.py @@ -44,6 +44,10 @@ templates = common_templates.node_library(source_location='build/src') s.copy(templates) +# Fix system tests +# TODO: must be a feature of pack-n-play +s.replace('system-test/fixtures/sample/src/index.*', "'texttospeech'", "'@google-cloud/text-to-speech'") + # Node.js specific cleanup subprocess.run(['npm', 'install']) subprocess.run(['npm', 'run', 'fix']) diff --git a/system-test/fixtures/sample/src/index.js b/system-test/fixtures/sample/src/index.js index 443142bb..e1636dae 100644 --- a/system-test/fixtures/sample/src/index.js +++ b/system-test/fixtures/sample/src/index.js @@ -16,7 +16,7 @@ // ** https://github.com/googleapis/gapic-generator-typescript ** // ** All changes to this file may be overwritten. ** -const texttospeech = require('texttospeech'); +const texttospeech = require('@google-cloud/text-to-speech'); function main() { const textToSpeechClient = new texttospeech.TextToSpeechClient(); diff --git a/system-test/fixtures/sample/src/index.ts b/system-test/fixtures/sample/src/index.ts index 2e64b80e..3d5e706f 100644 --- a/system-test/fixtures/sample/src/index.ts +++ b/system-test/fixtures/sample/src/index.ts @@ -16,7 +16,7 @@ // ** https://github.com/googleapis/gapic-generator-typescript ** // ** All changes to this file may be overwritten. ** -import {TextToSpeechClient} from 'texttospeech'; +import {TextToSpeechClient} from '@google-cloud/text-to-speech'; function main() { const textToSpeechClient = new TextToSpeechClient();