From 7ff86a1c5ba2aaffdc7196c963a4fd8e07ed9a21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alja=C5=BE=20Mur=20Er=C5=BEen?= Date: Mon, 25 Mar 2024 14:21:41 +0100 Subject: [PATCH] build: test for feat-types --- .github/workflows/test-feat-types.yaml | 23 +++++++++++++++++++++++ prqlc/Taskfile.yaml | 8 ++++++++ 2 files changed, 31 insertions(+) create mode 100644 .github/workflows/test-feat-types.yaml diff --git a/.github/workflows/test-feat-types.yaml b/.github/workflows/test-feat-types.yaml new file mode 100644 index 000000000000..24fe2cbb2a25 --- /dev/null +++ b/.github/workflows/test-feat-types.yaml @@ -0,0 +1,23 @@ +--- +name: Test feat-types +on: + push: + branches: [feat-types] + pull_request: + branches: [feat-types] +jobs: + test-job: + runs-on: ubuntu-latest + steps: + # checkout and env setup + - uses: actions/checkout@v3 + - uses: DeterminateSystems/nix-installer-action@main + - uses: DeterminateSystems/magic-nix-cache-action@main + - name: Build the nix shell + run: nix develop --command task --version + - uses: Swatinem/rust-cache@v2 + + # run tests + - name: Test prqlc + run: nix develop --command task test + working-directory: prqlc diff --git a/prqlc/Taskfile.yaml b/prqlc/Taskfile.yaml index e05ee4791884..1ddd0864159e 100644 --- a/prqlc/Taskfile.yaml +++ b/prqlc/Taskfile.yaml @@ -35,6 +35,12 @@ tasks: --ignore-unknown \ --log-level=warn + fmt-check: + desc: Validate that source files are formatted + cmds: + - cargo fmt --check {{.packages_core}} {{.packages_addon}} + {{.packages_bindings}} + test-fast: desc: A fast test used for feedback during compiler development cmds: @@ -53,6 +59,8 @@ tasks: # Use a different target dir so we don't poison the cache CARGO_LLVM_COV_TARGET_DIR: ../target-cov cmds: + - task: fmt-check + - cmd: | cargo \ llvm-cov --lcov --output-path lcov.info \