Skip to content

Commit

Permalink
build: test for feat-types
Browse files Browse the repository at this point in the history
  • Loading branch information
aljazerzen committed Mar 25, 2024
1 parent ee6b2ce commit 7dbe057
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 3 deletions.
4 changes: 2 additions & 2 deletions .config/nextest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ failure-output = "final"
slow-timeout = {period = "500ms", terminate-after = 4}

[[profile.default.overrides]]
filter = 'test(prqlc::queries::results::)'
slow-timeout = {period = "2s", terminate-after = 4}
filter = 'test(queries::results::)'
slow-timeout = {period = "4s", terminate-after = 4}
test-group = 'test-dbs'

[test-groups.test-dbs]
Expand Down
21 changes: 21 additions & 0 deletions .github/workflows/test-feat-types.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
---
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 prqlc:test
2 changes: 1 addition & 1 deletion flake.nix
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@
in
{
devShells.default = pkgs.mkShell {
buildInputs = essentials;
buildInputs = essentials ++ bindings;
};
devShells.web = pkgs.mkShell {
buildInputs = essentials ++ web;
Expand Down
8 changes: 8 additions & 0 deletions prqlc/Taskfile.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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 \
Expand Down

0 comments on commit 7dbe057

Please sign in to comment.