Skip to content

Commit 3c23d0f

Browse files
authored
Merge #4297 tests: set $TZ a different way
2 parents a7de210 + 3fb3955 commit 3c23d0f

File tree

7 files changed

+4
-18
lines changed

7 files changed

+4
-18
lines changed

.github/workflows/node.js.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,6 @@ jobs:
2121
env:
2222
VSCODE_TEST_VERSION: ${{ matrix.vscode-version }}
2323
NODE_OPTIONS: '--max-old-space-size=8192'
24-
# Set a fixed timezone for tests. Intentionally _not_ UTC.
25-
TZ: 'US/Pacific'
2624
steps:
2725
- uses: actions/checkout@v4
2826
- name: Use Node.js ${{ matrix.node-version }}
@@ -66,8 +64,6 @@ jobs:
6664
env:
6765
VSCODE_TEST_VERSION: ${{ matrix.vscode-version }}
6866
NODE_OPTIONS: '--max-old-space-size=8192'
69-
# Set a fixed timezone for tests. Intentionally _not_ UTC.
70-
TZ: 'US/Pacific'
7167
steps:
7268
- uses: actions/checkout@v4
7369
- name: Use Node.js ${{ matrix.node-version }}

buildspec/linuxE2ETests.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,7 @@ run-as: codebuild-user
55

66
env:
77
variables:
8-
# Set a fixed timezone for tests. Intentionally _not_ UTC.
9-
TZ: 'US/Pacific'
108
AWS_TOOLKIT_TEST_NO_COLOR: '1'
11-
NO_COVERAGE: 'true'
129
# Suppress noisy apt-get/dpkg warnings like "debconf: unable to initialize frontend: Dialog").
1310
DEBIAN_FRONTEND: 'noninteractive'
1411

buildspec/linuxIntegrationTests.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,6 @@ env:
99
# VSCODE_TEST_VERSION
1010
# GITHUB_READONLY_TOKEN
1111
AWS_TOOLKIT_TEST_NO_COLOR: '1'
12-
# Set a fixed timezone for tests. Intentionally _not_ UTC.
13-
TZ: 'US/Pacific'
14-
NO_COVERAGE: 'true'
1512
# Suppress noisy apt-get/dpkg warnings like "debconf: unable to initialize frontend: Dialog").
1613
DEBIAN_FRONTEND: 'noninteractive'
1714

buildspec/linuxTests.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,6 @@ env:
77
# For "pipefail".
88
shell: bash
99
variables:
10-
# Set a fixed timezone for tests. Intentionally _not_ UTC.
11-
TZ: 'US/Pacific'
1210
AWS_TOOLKIT_TEST_NO_COLOR: '1'
1311

1412
phases:

buildspec/windowsTests.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@ version: 0.2
22
env:
33
variables:
44
AWS_TOOLKIT_TEST_NO_COLOR: '1'
5-
# Set a fixed timezone for tests. Intentionally _not_ UTC.
6-
TZ: 'US/Pacific'
75
phases:
86
install:
97
runtime-versions:

scripts/test/launchTestUtilities.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,10 @@ import { runTests } from '@vscode/test-electron'
1111
import { VSCODE_EXTENSION_ID } from '../../src/shared/extensions'
1212
import { TestOptions } from '@vscode/test-electron/out/runTest'
1313

14+
// Set a fixed timezone. Intentionally _not_ UTC, to increase variation in tests.
15+
process.env.TZ = 'US/Pacific'
16+
// process.env.TZ = 'Europe/London'
17+
1418
const envvarVscodeTestVersion = 'VSCODE_TEST_VERSION'
1519

1620
const stable = 'stable'

src/test/globalSetup.test.ts

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,6 @@ let openExternalStub: sinon.SinonStub<Parameters<(typeof vscode)['env']['openExt
3737
// let executeCommandSpy: sinon.SinonSpy | undefined
3838

3939
export async function mochaGlobalSetup(this: Mocha.Runner) {
40-
// Set a fixed timezone. Intentionally _not_ UTC, to increase variation in tests.
41-
process.env.TZ = 'US/Pacific'
42-
// process.env.TZ = 'Europe/London'
43-
4440
// Clean up and set up test logs
4541
try {
4642
await remove(testLogOutput)

0 commit comments

Comments
 (0)