Skip to content

Commit

Permalink
test: add functional test to verify false feature inputs with auto-co…
Browse files Browse the repository at this point in the history
…nfig: true
  • Loading branch information
austinletson committed Nov 23, 2024
1 parent 657d852 commit 8196f26
Showing 1 changed file with 38 additions and 1 deletion.
39 changes: 38 additions & 1 deletion .github/functional_tests/auto_config_true/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ description: |
Run `lean-action` with `auto-config: true` and no feature inputs
on a package generated with `lake init` and a dummy test runner added.
Verify `lake build` and `lake test` run successfully.
Run `lean-action` with `auto-config:true` and false feature inputs.
Verify `lake build` and `lake test` did not run.
inputs:
toolchain:
description: 'Toolchain to use for the test'
Expand Down Expand Up @@ -46,7 +49,7 @@ runs:
} >> lakefile.lean
shell: bash

- name: "run `lean-action` with `lake test`"
- name: "run `lean-action` with auto-config: true"
id: lean-action
uses: ./
with:
Expand Down Expand Up @@ -84,3 +87,37 @@ runs:
ACTUAL_VALUE: ${{ steps.lean-action.outputs.lint-status }}
run: .github/functional_tests/test_helpers/verify_action_output.sh
shell: bash


- name: "run `lean-action` with auto-config: true and false feature inputs"
id: lean-action-false-feature-inputs
uses: ./
with:
auto-config: true
build: false
test: false
lint: false
use-github-cache: false
- name: verify `lake build` did not run
env:
OUTPUT_NAME: "build-status"
EXPECTED_VALUE: ""
ACTUAL_VALUE: ${{ steps.lean-action-false-feature-inputs.outputs.build-status }}
run: .github/functional_tests/test_helpers/verify_action_output.sh
shell: bash

- name: verify `lake test` did not run
env:
OUTPUT_NAME: "test-status"
EXPECTED_VALUE: ""
ACTUAL_VALUE: ${{ steps.lean-action-false-feature-inputs.outputs.test-status }}
run: .github/functional_tests/test_helpers/verify_action_output.sh
shell: bash

- name: verify `lake lint` did not run
env:
OUTPUT_NAME: "lint-status"
EXPECTED_VALUE: ""
ACTUAL_VALUE: ${{ steps.lean-action-false-feature-inputs.outputs.lint-status }}
run: .github/functional_tests/test_helpers/verify_action_output.sh
shell: bash

0 comments on commit 8196f26

Please sign in to comment.