Skip to content

Commit

Permalink
feat: BI-5768 add action for test k8s-runners (#613)
Browse files Browse the repository at this point in the history
* feat: BI-5768 add action for test k8s-runners

* test new fats

* add no_compose labels
  • Loading branch information
flukolo4ek authored Oct 4, 2024
1 parent 733f9ec commit 1a26079
Show file tree
Hide file tree
Showing 31 changed files with 53 additions and 12 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ jobs:
/bin/bash ci/build_naive.sh
router:
runs-on: [ self-hosted, linux, light ]
runs-on: [ self-hosted, linux, k8s-runner-no-compose ]
needs: gh_build_image
container:
image: "ghcr.io/${{ github.repository_owner }}/${{ github.event.repository.name }}/datalens_ci_with_code:${{ github.sha }}"
Expand Down Expand Up @@ -246,7 +246,7 @@ jobs:

pytest_split:
name: Split pytest into jobs for each test type
runs-on: [ self-hosted, linux, light ]
runs-on: [ self-hosted, linux, k8s-runner-no-compose ]

needs: [ router, check-skip-tests-label ]
if: ${{ needs.check-skip-tests-label.outputs.result != 'true' }}
Expand Down Expand Up @@ -445,7 +445,7 @@ jobs:
run_tests_ext_public:
name: "🐍[pytest][ext_public]${{ matrix.value }}"
# using light runners for now, TBD: change when we have ext_public
runs-on: [ self-hosted, linux, light ]
runs-on: [ self-hosted, linux, k8s-runner-ext-public ]
permissions:
packages: read
contents: read
Expand Down Expand Up @@ -502,7 +502,7 @@ jobs:
retention-days: 1

mypy:
runs-on: [ self-hosted, linux, light ]
runs-on: [ self-hosted, linux, k8s-runner-no-compose ]
needs: gh_build_image
container:
# until https://github.com/github/docs/issues/25520 is resolved, using vars
Expand Down Expand Up @@ -557,7 +557,7 @@ jobs:
echo "All tests passed"
codestyle_all:
runs-on: [ self-hosted, linux, light ]
runs-on: [ self-hosted, linux, k8s-runner-no-compose ]
needs: gh_build_image
container:
# until https://github.com/github/docs/issues/25520 is resolved, using vars
Expand Down
1 change: 1 addition & 0 deletions lib/dl_api_client/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ testpaths = []
root_dir = "dl_api_client_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_api_commons/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ testpaths = []
root_dir = "dl_api_commons_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_api_connector/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ testpaths = ["dl_api_connector_tests/unit"]
root_dir = "dl_api_connector_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_api_lib/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ timeout = 600
root_dir = "dl_api_lib_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.db]
root_dir = "dl_api_lib_tests/"
Expand Down
4 changes: 2 additions & 2 deletions lib/dl_auth_api_lib/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -39,10 +39,10 @@ minversion = "6.0"
addopts = "-ra"
testpaths = ["dl_auth_api_lib_tests/ext", "dl_auth_api_lib_tests/unit"]

[datalens.pytest.local]
[datalens.pytest.unit]
root_dir = "dl_auth_api_lib_tests/"
target_path = "unit"
labels = ["fat"]
labels = ["no_compose"]

[datalens.pytest.ext]
root_dir = "dl_auth_api_lib_tests/"
Expand Down
1 change: 1 addition & 0 deletions lib/dl_configs/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ testpaths = []
root_dir = "dl_configs_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_connector_bigquery/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ testpaths = ["dl_connector_bigquery_tests/ext", "dl_connector_bigquery_tests/uni
[datalens.pytest.unit]
root_dir = "dl_connector_bigquery_tests/unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.ext]
root_dir = "dl_connector_bigquery_tests/ext"
Expand Down
1 change: 1 addition & 0 deletions lib/dl_connector_bitrix_gds/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ labels = ["ext_public"]
root_dir = "dl_connector_bitrix_gds_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_connector_chyt/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ testpaths = []
root_dir = "dl_connector_chyt_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
8 changes: 6 additions & 2 deletions lib/dl_connector_clickhouse/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -76,11 +76,15 @@ testpaths = ["dl_connector_clickhouse_tests/db", "dl_connector_clickhouse_tests/


[datalens.pytest.unit]
root_dir = "dl_connector_clickhouse_tests/unit"
root_dir = "dl_connector_clickhouse_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.db]
root_dir = "dl_connector_clickhouse_tests/db"
root_dir = "dl_connector_clickhouse_tests/"
target_path = "db"
labels = ["fat"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_connector_greenplum/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,7 @@ target_path = "db"
root_dir = "dl_connector_greenplum_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_connector_metrica/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ labels = ["ext_public"]
root_dir = "dl_connector_metrica_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
4 changes: 3 additions & 1 deletion lib/dl_connector_mssql/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,12 +68,14 @@ testpaths = ["dl_connector_mssql_tests/db", "dl_connector_mssql_tests/unit"]

[datalens.pytest.db]
root_dir = "dl_connector_mssql_tests/"
target_path = "db unit"
target_path = "db"
labels=["fat"]

[datalens.pytest.unit]
root_dir = "dl_connector_mssql_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
11 changes: 9 additions & 2 deletions lib/dl_connector_mysql/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,16 @@ minversion = "6.0"
addopts = "-ra"
testpaths = ["dl_connector_mysql_tests/db", "dl_connector_mysql_tests/unit"]

[datalens.pytest.local]
[datalens.pytest.db]
root_dir = "dl_connector_mysql_tests/"
target_path = "db unit"
target_path = "db"
labels=["fat"]

[datalens.pytest.unit]
root_dir = "dl_connector_mysql_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
2 changes: 2 additions & 0 deletions lib/dl_connector_oracle/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,13 @@ testpaths = ["dl_connector_oracle_tests/db", "dl_connector_oracle_tests/unit"]
[datalens.pytest.db]
root_dir = "dl_connector_oracle_tests/"
target_path = "db"
labels = ["fat"]

[datalens.pytest.unit]
root_dir = "dl_connector_oracle_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_connector_promql/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ target_path = "db"
root_dir = "dl_connector_promql_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_connector_snowflake/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,7 @@ skip_tests = true
root_dir = "dl_connector_snowflake_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
2 changes: 2 additions & 0 deletions lib/dl_connector_ydb/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,13 @@ testpaths = []
root_dir = "dl_connector_ydb_tests/"
target_path = "db"
compose_file_base = "docker-compose"
labels = ["fat"]

[datalens.pytest.unit]
root_dir = "dl_connector_ydb_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_core/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ timeout = 600
root_dir = "dl_core_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.db]
root_dir = "dl_core_tests/"
Expand Down
1 change: 1 addition & 0 deletions lib/dl_formula/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ testpaths = []
root_dir = "dl_formula_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.poetry.scripts]
bi-formula-cli = "dl_formula.scripts.formula_cli:main"
Expand Down
1 change: 1 addition & 0 deletions lib/dl_formula_ref/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ testpaths = []
root_dir = "dl_formula_ref_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.db]
root_dir = "dl_formula_ref_tests/"
Expand Down
1 change: 1 addition & 0 deletions lib/dl_model_tools/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ testpaths = []
root_dir = "dl_model_tools_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_query_processing/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ timeout = 600
root_dir = "dl_query_processing_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_rate_limiter/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ strict_optional = true
[datalens.pytest.unit]
root_dir = "dl_rate_limiter_tests/unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.db]
root_dir = "dl_rate_limiter_tests/db"
Expand Down
1 change: 1 addition & 0 deletions lib/dl_rls/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ testpaths = []
root_dir = "dl_rls_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_sqlalchemy_bitrix/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ testpaths = ["dl_sqlalchemy_bitrix_tests/unit"]
root_dir = "dl_sqlalchemy_bitrix_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.meta.mypy]
targets = [] # ignore mypy in entire module
Expand Down
1 change: 1 addition & 0 deletions lib/dl_task_processor/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ asyncio_mode = "auto"
root_dir = "dl_task_processor_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.db]
root_dir = "dl_task_processor_tests/"
Expand Down
1 change: 1 addition & 0 deletions lib/dl_testing/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ testpaths = []
root_dir = "dl_testing_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_type_transformer/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ testpaths = []
root_dir = "dl_type_transformer_tests/"
target_path = "unit"
skip_compose = "true"
labels = ["no_compose"]

[tool.mypy]
warn_unused_configs = true
Expand Down
1 change: 1 addition & 0 deletions lib/dl_zitadel/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ strict_optional = true
[datalens.pytest.unit]
root_dir = "dl_zitadel_tests/unit"
skip_compose = "true"
labels = ["no_compose"]

[datalens.pytest.db]
root_dir = "dl_zitadel_tests/db"
Expand Down

0 comments on commit 1a26079

Please sign in to comment.