From f2d79e5b2eb3a510d3608b36fe6ea8650dbefaec Mon Sep 17 00:00:00 2001 From: Cai Parry-Jones Date: Sat, 15 Mar 2025 13:41:41 +0000 Subject: [PATCH 1/4] as branch --- .github/workflows/pytest.yml | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 .github/workflows/pytest.yml diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml new file mode 100644 index 0000000..325f3a1 --- /dev/null +++ b/.github/workflows/pytest.yml @@ -0,0 +1,29 @@ +name: Python Tests + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +jobs: + test: + runs-on: ubuntu-latest + strategy: + matrix: + python-version: [3.8, 3.9, '3.10'] + + steps: + - uses: actions/checkout@v3 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v4 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install pytest + if [ -f requirements.txt ]; then pip install -r requirements.txt; fi + - name: Test with pytest + run: | + pytest \ No newline at end of file From 8b70a2f5fe214fa12c3052721634ba54ed4e242e Mon Sep 17 00:00:00 2001 From: Cai Parry-Jones Date: Sat, 15 Mar 2025 18:13:40 +0000 Subject: [PATCH 2/4] req for tests --- data_quality/requirements.txt | 2 +- tests/requirements.txt | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) create mode 100644 tests/requirements.txt diff --git a/data_quality/requirements.txt b/data_quality/requirements.txt index 7a96e1c..e2862f3 100644 --- a/data_quality/requirements.txt +++ b/data_quality/requirements.txt @@ -7,7 +7,7 @@ pandas>=2.0.0 # data handling termcolor>=2.3.0 # colored terminal output # Database drivers (uncomment your database type) -# duckdb>=0.9.0 # DuckDB +# duckdb>=1.0.0 # DuckDB # psycopg2-binary>=2.9.0 # PostgreSQL # sqlalchemy>=2.0.0 # PostgreSQL via SQLAlchemy # trino>=0.327.0 # Trino diff --git a/tests/requirements.txt b/tests/requirements.txt new file mode 100644 index 0000000..e419dce --- /dev/null +++ b/tests/requirements.txt @@ -0,0 +1,6 @@ +pyyaml>=6.0 # YAML file handling +jinja2>=3.1.0 # template rendering +pandas>=2.0.0 # data handling +termcolor>=2.3.0 # colored terminal output +duckdb>=1.0.0 # DuckDB +sqlglot>=10.0.0 # extracting tables in SQL files From acfb1feb5c0625230024ea8e5a846963f0afe338 Mon Sep 17 00:00:00 2001 From: Cai Parry-Jones Date: Sat, 15 Mar 2025 18:16:56 +0000 Subject: [PATCH 3/4] fix --- .github/workflows/pytest.yml | 5 ++--- tests/requirements.txt | 13 +++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index 325f3a1..92f6bb6 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -11,7 +11,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - python-version: [3.8, 3.9, '3.10'] + python-version: ['3.12.2'] steps: - uses: actions/checkout@v3 @@ -22,8 +22,7 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install pytest - if [ -f requirements.txt ]; then pip install -r requirements.txt; fi + pip install -r tests/requirements.txt; fi - name: Test with pytest run: | pytest \ No newline at end of file diff --git a/tests/requirements.txt b/tests/requirements.txt index e419dce..3fde8c9 100644 --- a/tests/requirements.txt +++ b/tests/requirements.txt @@ -1,6 +1,7 @@ -pyyaml>=6.0 # YAML file handling -jinja2>=3.1.0 # template rendering -pandas>=2.0.0 # data handling -termcolor>=2.3.0 # colored terminal output -duckdb>=1.0.0 # DuckDB -sqlglot>=10.0.0 # extracting tables in SQL files +pyyaml>=6.0 +jinja2>=3.1.0 +pandas>=2.0.0 +termcolor>=2.3.0 +duckdb>=1.0.0 +sqlglot>=10.0.0 +pytest>=8.3.3 \ No newline at end of file From 489e1ccd9f413c26cdf7ca6adeae459cc96fca02 Mon Sep 17 00:00:00 2001 From: Cai Parry-Jones Date: Sat, 15 Mar 2025 18:18:34 +0000 Subject: [PATCH 4/4] fix --- .github/workflows/pytest.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/pytest.yml b/.github/workflows/pytest.yml index 92f6bb6..62d3565 100644 --- a/.github/workflows/pytest.yml +++ b/.github/workflows/pytest.yml @@ -22,7 +22,7 @@ jobs: - name: Install dependencies run: | python -m pip install --upgrade pip - pip install -r tests/requirements.txt; fi + pip install -r tests/requirements.txt - name: Test with pytest run: | pytest \ No newline at end of file