From e70bb9131e0cc51de257735219b8e76c71be4336 Mon Sep 17 00:00:00 2001 From: "pattishin@google.com" Date: Thu, 6 Apr 2023 12:18:22 -0700 Subject: [PATCH 1/2] fix: matching test names with region tags per enforcer requirements --- .../hello-world/flexible_nodejs16_and_earlier/test/app.test.js | 2 +- .../metadata/flexible_nodejs16_and_earlier/test/server.test.js | 2 +- .../flexible_nodejs16_and_earlier/system-test/app.test.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js b/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js index 727151de7d..b0dd6fbec0 100644 --- a/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js +++ b/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js @@ -1,7 +1,7 @@ const app = require('../app'); const request = require('supertest'); -describe('gae_flex_quickstart', () => { +describe('gae_flex_quickstart_v1', () => { describe('GET /', () => { it('should get 200', done => { request(app).get('/').expect(200, done); diff --git a/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js b/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js index 59f2197743..484f212590 100644 --- a/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js +++ b/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js @@ -2,7 +2,7 @@ const path = require('path'); const app = require(path.join(__dirname, '../', 'server.js')); const supertest = require('supertest'); -describe('gae_flex_metadata', () => { +describe('gae_flex_metadata_v1', () => { it('should be listening', async () => { await supertest(app).get('/').expect(200); }); diff --git a/appengine/storage/flexible_nodejs16_and_earlier/system-test/app.test.js b/appengine/storage/flexible_nodejs16_and_earlier/system-test/app.test.js index ef8b88919a..6145f170ee 100644 --- a/appengine/storage/flexible_nodejs16_and_earlier/system-test/app.test.js +++ b/appengine/storage/flexible_nodejs16_and_earlier/system-test/app.test.js @@ -57,7 +57,7 @@ after(async () => { } }); -describe('gae_flex_storage_app', () => { +describe('gae_flex_storage_app_v1', () => { it('should load', async () => { await requestObj .get('/') From d1065d9608bdf94c760e83bdbad438be72c84c23 Mon Sep 17 00:00:00 2001 From: "pattishin@google.com" Date: Thu, 6 Apr 2023 12:23:58 -0700 Subject: [PATCH 2/2] refactor: add missing headers --- .../flexible_nodejs16_and_earlier/test/app.test.js | 14 ++++++++++++++ .../test/server.test.js | 14 ++++++++++++++ 2 files changed, 28 insertions(+) diff --git a/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js b/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js index b0dd6fbec0..ffd20215f8 100644 --- a/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js +++ b/appengine/hello-world/flexible_nodejs16_and_earlier/test/app.test.js @@ -1,3 +1,17 @@ +// Copyright 2023 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + const app = require('../app'); const request = require('supertest'); diff --git a/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js b/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js index 484f212590..eff747a7b5 100644 --- a/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js +++ b/appengine/metadata/flexible_nodejs16_and_earlier/test/server.test.js @@ -1,3 +1,17 @@ +// Copyright 2023 Google LLC +// +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + const path = require('path'); const app = require(path.join(__dirname, '../', 'server.js')); const supertest = require('supertest');