Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[sqlserver] run sqlserver test in non-utc timezone #19135

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions sqlserver/hatch.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,13 @@ os = ["linux"]
version = ["2017", "2019", "2022"]
setup = ["single", "ha"]

# test the compatibility of sqlserver running on non-utc timezone
[[envs.default.matrix]]
python = ["3.12"]
os = ["linux"]
version = ["2022"]
tz = ["newyork", "tokyo"]

# test the full combination of python-version/driver against a the latest sql server version
# ideally we'd test this against all sql server versions but that makes the test take too long and time out.
# time out. until we're able to modify and parallelize the work we'll limit the per-driver tests to only a single
Expand All @@ -32,6 +39,7 @@ setup = ["single"]
[envs.default.env-vars]
ODBCSYSINI = "{root}{/}tests{/}odbc"
COMPOSE_FOLDER = "compose"
TZ="UTC"
PIP_EXTRA_INDEX_URL = "https://datadoghq.dev/ci-wheels/bin"

[envs.default.overrides]
Expand Down Expand Up @@ -62,6 +70,10 @@ matrix.version.env-vars = [
matrix.driver.env-vars = [
{ key = "WINDOWS_SQLSERVER_DRIVER", platform = ["windows"] },
]
matrix.tz.env-vars = [
{ key = "TZ", value = "America/New_York", if = ["newyork"] },
{ key = "TZ", value = "Asia/Tokyo", if = ["tokyo"] },
]
name.linux-odbc-2019-high-cardinality.env-vars = "COMPOSE_FOLDER=compose-high-cardinality"
name.linux-odbc-2022-high-cardinality.env-vars = "COMPOSE_FOLDER=compose-high-cardinality"
name.windows-odbc-2019-high-cardinality.env-vars = "COMPOSE_FOLDER=compose-high-cardinality-windows"
1 change: 1 addition & 0 deletions sqlserver/tests/compose/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ services:
environment:
- ACCEPT_EULA=Y
- SA_PASSWORD=Password123
- TZ=${TZ}
ports:
- "1433:1433"
volumes:
Expand Down
Loading