Skip to content
This repository was archived by the owner on Mar 29, 2023. It is now read-only.

Commit bb171c4

Browse files
loudinbtswast
andauthored
test: populate tables for system test using pytest fixtures #51 (#60)
* test: populate tables for system test using pytest fixtures #51 * test: fixed import order lint errror, fixed numeric test error #51 * allow dataset to not exist when trying to delete it * try adding autouse=True to the dataset fixture * typo in autouse * remove ibis v2 from v1 branch tests * add option to not refresh dataset * use more specific dataset ID * save dataset on ibis-gbq project Co-authored-by: Tim Swast <swast@google.com>
1 parent 86594aa commit bb171c4

File tree

8 files changed

+368
-111
lines changed

8 files changed

+368
-111
lines changed

.github/workflows/main.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,14 @@ jobs:
5353
strategy:
5454
fail-fast: false
5555
matrix:
56-
python_version: ["3.7", "3.8", "3.9"]
57-
ibis_version: ["github"]
5856
include:
5957
- python_version: "3.7"
6058
"ibis_version": "1.2.0"
61-
- python_version: "3.7"
62-
"ibis_version": "1.3.0"
6359
- python_version: "3.8"
60+
"ibis_version": "1.3.0"
61+
- python_version: "3.9"
62+
"ibis_version": "1.4.0"
63+
- python_version: "3.10"
6464
"ibis_version": "1.4.0"
6565

6666
steps:

.github/workflows/system-tests-pr.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,12 @@ jobs:
1717
strategy:
1818
fail-fast: false
1919
matrix:
20-
python_version: ["3.7", "3.8", "3.9"]
21-
ibis_version: ["github"]
2220
include:
2321
- python_version: "3.7"
2422
"ibis_version": "1.2.0"
25-
- python_version: "3.7"
26-
"ibis_version": "1.3.0"
2723
- python_version: "3.8"
24+
"ibis_version": "1.3.0"
25+
- python_version: "3.10"
2826
"ibis_version": "1.4.0"
2927

3028
steps:
@@ -55,7 +53,7 @@ jobs:
5553
GCLOUD_KEY_PASSPHRASE: ${{ secrets.GCLOUD_KEY_PASSPHRASE }}
5654

5755
- name: run tests
58-
run: GOOGLE_BIGQUERY_PROJECT_ID="ibis-gbq" GOOGLE_APPLICATION_CREDENTIALS="$HOME/secrets/gcloud-service-key.json" python -m pytest tests/system
56+
run: GOOGLE_BIGQUERY_PROJECT_ID="ibis-gbq" GOOGLE_APPLICATION_CREDENTIALS="$HOME/secrets/gcloud-service-key.json" python -m pytest tests/system --save-dataset
5957

6058
# Remove the label so that it can be added again to re-trigger a build
6159
- name: reset label

.github/workflows/system-tests.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,12 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18-
python_version: ["3.7", "3.8", "3.9"]
1918
ibis_version: ["github"]
20-
include:
2119
- python_version: "3.7"
2220
"ibis_version": "1.2.0"
23-
- python_version: "3.7"
24-
"ibis_version": "1.3.0"
2521
- python_version: "3.8"
22+
"ibis_version": "1.3.0"
23+
- python_version: "3.10"
2624
"ibis_version": "1.4.0"
2725

2826
steps:
@@ -51,4 +49,4 @@ jobs:
5149
GCLOUD_KEY_PASSPHRASE: ${{ secrets.GCLOUD_KEY_PASSPHRASE }}
5250

5351
- name: run tests
54-
run: GOOGLE_BIGQUERY_PROJECT_ID="ibis-gbq" GOOGLE_APPLICATION_CREDENTIALS="$HOME/secrets/gcloud-service-key.json" python -m pytest tests/system
52+
run: GOOGLE_BIGQUERY_PROJECT_ID="ibis-gbq" GOOGLE_APPLICATION_CREDENTIALS="$HOME/secrets/gcloud-service-key.json" python -m pytest tests/system --save-dataset

environment.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
name: ibis-bigquery-dev
1+
name: ibis-v1-bigquery-dev
22
channels:
33
- conda-forge
44
dependencies:
55

66
# core
7-
- ibis-framework # TODO: require Ibis 2.0 when it's released
8-
- cached_property # New in Ibis 2.0 https://github.com/ibis-project/ibis/pull/2805
7+
- ibis-framework <=2.0.0dev
98
- google-cloud-bigquery-core >=1.12.0,<3.0.0dev
109
- pydata-google-auth
10+
- sqlalchemy=1.3.23
1111

1212
# dev
1313
- black=19.10b0 # Same as ibis

setup.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,14 @@
4141
packages=setuptools.find_packages(),
4242
python_requires=">=3.7",
4343
install_requires=[
44-
# TODO require ibis 2.0 when it's released
45-
"ibis-framework >= 1.2.0,<3.0.0dev",
44+
"ibis-framework >=1.2.0,<2.0.0dev",
4645
"google-cloud-bigquery >=1.12.0,<3.0.0dev",
4746
"google-cloud-bigquery-storage >=1.0.0,<3.0.0dev",
4847
"pyarrow >=1.0.0,<5.0.0dev",
4948
"pydata-google-auth",
49+
# Workaround for ibis 1.x incompatibility with SQLAlchemy 1.4
50+
# AttributeError: module 'sqlalchemy' has no attribute 'Binary'
51+
"sqlalchemy <1.4.0dev",
5052
],
5153
classifiers=[
5254
release_status,

0 commit comments

Comments
 (0)