Skip to content

Commit e9c183f

Browse files
authored
ci: Remove dev environment (#93)
1 parent 88db988 commit e9c183f

File tree

5 files changed

+17
-114
lines changed

5 files changed

+17
-114
lines changed

.github/workflows/integration-tests-v1.yml

Lines changed: 7 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -2,26 +2,8 @@ name: v1 Integration tests
22

33
on:
44
workflow_dispatch:
5-
inputs:
6-
environment:
7-
description: 'Environment to run the tests against'
8-
type: choice
9-
required: true
10-
default: 'dev'
11-
options:
12-
- dev
13-
- staging
145
workflow_call:
15-
inputs:
16-
environment:
17-
default: 'staging'
18-
required: false
19-
type: string
206
secrets:
21-
FIREBOLT_USERNAME:
22-
required: true
23-
FIREBOLT_PASSWORD:
24-
required: true
257
FIREBOLT_STG_USERNAME:
268
required: true
279
FIREBOLT_STG_PASSWORD:
@@ -44,23 +26,13 @@ jobs:
4426
python -m pip install --upgrade pip
4527
pip install ".[dev]"
4628
47-
- name: Determine env variables
48-
run: |
49-
if [ "${{ inputs.environment }}" == 'staging' ]; then
50-
echo "USERNAME=${{ secrets.FIREBOLT_STG_USERNAME }}" >> "$GITHUB_ENV"
51-
echo "PASSWORD=${{ secrets.FIREBOLT_STG_PASSWORD }}" >> "$GITHUB_ENV"
52-
else
53-
echo "USERNAME=${{ secrets.FIREBOLT_USERNAME }}" >> "$GITHUB_ENV"
54-
echo "PASSWORD=${{ secrets.FIREBOLT_PASSWORD }}" >> "$GITHUB_ENV"
55-
fi
56-
5729
- name: Setup database and engine
5830
id: setup
5931
uses: firebolt-db/integration-testing-setup@v1
6032
with:
61-
firebolt-username: ${{ env.USERNAME }}
62-
firebolt-password: ${{ env.PASSWORD }}
63-
api-endpoint: "api.${{ inputs.environment }}.firebolt.io"
33+
firebolt-username: ${{ secrets.FIREBOLT_STG_USERNAME }}
34+
firebolt-password: ${{ secrets.FIREBOLT_STG_PASSWORD }}
35+
api-endpoint: "api.staging.firebolt.io"
6436
region: "us-east-1"
6537

6638
- name: Restore cached failed tests
@@ -74,14 +46,14 @@ jobs:
7446
- name: Run integration tests
7547
env:
7648
# the distinction is on the SDK side so just use CLIENT_* for username password
77-
CLIENT_ID: ${{ env.USERNAME }}
78-
CLIENT_SECRET: ${{ env.PASSWORD }}
49+
CLIENT_ID: ${{ secrets.FIREBOLT_STG_USERNAME }}
50+
CLIENT_SECRET: ${{ secrets.FIREBOLT_STG_PASSWORD }}
7951
DATABASE_NAME: ${{ steps.setup.outputs.database_name }}
8052
ENGINE_NAME: ${{ steps.setup.outputs.engine_name }}
8153
ENGINE_URL: ${{ steps.setup.outputs.engine_url }}
8254
STOPPED_ENGINE_NAME: ${{ steps.setup.outputs.stopped_engine_name }}
8355
STOPPED_ENGINE_URL: ${{ steps.setup.outputs.stopped_engine_url }}
84-
FIREBOLT_BASE_URL: "api.${{ inputs.environment }}.firebolt.io"
56+
FIREBOLT_BASE_URL: "api.staging.firebolt.io"
8557
ACCOUNT_NAME: "firebolt"
8658
run: |
8759
pytest --last-failed -o log_cli=true -o log_cli_level=INFO tests/integration
@@ -93,4 +65,4 @@ jobs:
9365
with:
9466
path: |
9567
.pytest_cache/v/cache/lastfailed
96-
key: ${{ steps.cache-tests-restore.outputs.cache-primary-key }}
68+
key: ${{ steps.cache-tests-restore.outputs.cache-primary-key }}

.github/workflows/integration-tests-v2.yml

Lines changed: 8 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -2,30 +2,12 @@ name: v2 Integration tests
22

33
on:
44
workflow_dispatch:
5-
inputs:
6-
environment:
7-
description: 'Environment to run the tests against'
8-
type: choice
9-
required: true
10-
default: 'dev'
11-
options:
12-
- dev
13-
- staging
145
workflow_call:
15-
inputs:
16-
environment:
17-
default: 'staging'
18-
required: false
19-
type: string
206
secrets:
217
FIREBOLT_CLIENT_ID_STG_NEW_IDN:
228
required: true
239
FIREBOLT_CLIENT_SECRET_STG_NEW_IDN:
2410
required: true
25-
FIREBOLT_CLIENT_ID_NEW_IDN:
26-
required: true
27-
FIREBOLT_CLIENT_SECRET_NEW_IDN:
28-
required: true
2911

3012
jobs:
3113
integration-tests:
@@ -44,24 +26,14 @@ jobs:
4426
python -m pip install --upgrade pip
4527
pip install ".[dev]"
4628
47-
- name: Determine env variables
48-
run: |
49-
if [ "${{ inputs.environment }}" == 'staging' ]; then
50-
echo "CLIENT_ID=${{ secrets.FIREBOLT_CLIENT_ID_STG_NEW_IDN }}" >> "$GITHUB_ENV"
51-
echo "CLIENT_SECRET=${{ secrets.FIREBOLT_CLIENT_SECRET_STG_NEW_IDN }}" >> "$GITHUB_ENV"
52-
else
53-
echo "CLIENT_ID=${{ secrets.FIREBOLT_CLIENT_ID_NEW_IDN }}" >> "$GITHUB_ENV"
54-
echo "CLIENT_SECRET=${{ secrets.FIREBOLT_CLIENT_SECRET_NEW_IDN }}" >> "$GITHUB_ENV"
55-
fi
56-
5729
- name: Setup database and engine
5830
id: setup
5931
uses: firebolt-db/integration-testing-setup@v2
6032
with:
61-
firebolt-client-id: ${{ env.CLIENT_ID }}
62-
firebolt-client-secret: ${{ env.CLIENT_SECRET }}
63-
account: "developer"
64-
api-endpoint: "api.${{ inputs.environment }}.firebolt.io"
33+
firebolt-client-id: ${{ secrets.FIREBOLT_CLIENT_ID_STG_NEW_IDN }}
34+
firebolt-client-secret: ${{ secrets.FIREBOLT_CLIENT_SECRET_STG_NEW_IDN }}
35+
account: ${{ vars.FIREBOLT_ACCOUNT }}
36+
api-endpoint: "api.staging.firebolt.io"
6537

6638
- name: Restore cached failed tests
6739
id: cache-tests-restore
@@ -73,13 +45,13 @@ jobs:
7345

7446
- name: Run integration tests
7547
env:
76-
CLIENT_ID: ${{ env.CLIENT_ID }}
77-
CLIENT_SECRET: ${{ env.CLIENT_SECRET }}
48+
CLIENT_ID: ${{ secrets.FIREBOLT_CLIENT_ID_STG_NEW_IDN }}
49+
CLIENT_SECRET: ${{ secrets.FIREBOLT_CLIENT_SECRET_STG_NEW_IDN }}
7850
DATABASE_NAME: ${{ steps.setup.outputs.database_name }}
7951
ENGINE_NAME: ${{ steps.setup.outputs.engine_name }}
8052
STOPPED_ENGINE_NAME: ${{ steps.setup.outputs.stopped_engine_name }}
81-
FIREBOLT_BASE_URL: "api.${{ inputs.environment }}.firebolt.io"
82-
ACCOUNT_NAME: "developer"
53+
FIREBOLT_BASE_URL: "api.staging.firebolt.io"
54+
ACCOUNT_NAME: ${{ vars.FIREBOLT_ACCOUNT }}
8355
run: |
8456
pytest --last-failed -o log_cli=true -o log_cli_level=INFO tests/integration
8557

.github/workflows/nightly-v2.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ jobs:
4747
with:
4848
firebolt-client-id: ${{ secrets.FIREBOLT_CLIENT_ID_STG_NEW_IDN }}
4949
firebolt-client-secret: ${{ secrets.FIREBOLT_CLIENT_SECRET_STG_NEW_IDN }}
50-
account: "developer"
50+
account: ${{ vars.FIREBOLT_ACCOUNT }}
5151
api-endpoint: "api.staging.firebolt.io"
5252
db_suffix: ${{ format('{0}_{1}', matrix.os, matrix.python-version) }}
5353

@@ -67,7 +67,7 @@ jobs:
6767
ENGINE_NAME: ${{ steps.setup.outputs.engine_name }}
6868
STOPPED_ENGINE_NAME: ${{ steps.setup.outputs.stopped_engine_name }}
6969
FIREBOLT_BASE_URL: "api.staging.firebolt.io"
70-
ACCOUNT_NAME: "developer"
70+
ACCOUNT_NAME: ${{ vars.FIREBOLT_ACCOUNT }}
7171
run: |
7272
pytest --last-failed -o log_cli=true -o log_cli_level=INFO --junit-xml=report/junit.xml tests/integration
7373
Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,8 @@
11
name: Integration tests
22
on:
33
workflow_dispatch:
4-
inputs:
5-
environment:
6-
description: 'Environment to run the tests against'
7-
type: choice
8-
required: true
9-
default: 'dev'
10-
options:
11-
- dev
12-
- staging
134
workflow_call:
14-
inputs:
15-
environment:
16-
default: 'staging'
17-
required: false
18-
type: string
195
secrets:
20-
FIREBOLT_USERNAME:
21-
required: true
22-
FIREBOLT_PASSWORD:
23-
required: true
246
FIREBOLT_STG_USERNAME:
257
required: true
268
FIREBOLT_STG_PASSWORD:
@@ -30,18 +12,10 @@ on:
3012
required: true
3113
FIREBOLT_CLIENT_SECRET_STG_NEW_IDN:
3214
required: true
33-
FIREBOLT_CLIENT_ID_NEW_IDN:
34-
required: true
35-
FIREBOLT_CLIENT_SECRET_NEW_IDN:
36-
required: true
3715
jobs:
3816
integration-test-v1:
3917
uses: ./.github/workflows/integration-tests-v1.yml
40-
with:
41-
environment: ${{ inputs.environment }}
4218
secrets: inherit
4319
integration-test-v2:
4420
uses: ./.github/workflows/integration-tests-v2.yml
45-
with:
46-
environment: ${{ inputs.environment }}
4721
secrets: inherit

tests/integration/test_sqlalchemy_integration.py

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -74,21 +74,6 @@ def test_agg_index(self, connection: Connection, fact_table_name: str):
7474
)
7575
connection.execute(text(f"DROP AGGREGATING INDEX {agg_index}"))
7676

77-
def test_join_index(self, connection: Connection, dimension_table_name: str):
78-
# Test if sql parsing allows it
79-
join_index = "idx_join"
80-
connection.execute(
81-
text(
82-
f"""
83-
CREATE JOIN INDEX {join_index} ON {dimension_table_name} (
84-
idx,
85-
dummy
86-
);
87-
"""
88-
)
89-
)
90-
connection.execute(text(f"DROP JOIN INDEX {join_index}"))
91-
9277
def test_get_schema_names(self, engine: Engine, database_name: str):
9378
results = engine.dialect.get_schema_names(engine)
9479
assert "public" in results

0 commit comments

Comments
 (0)