-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtests.bats
More file actions
32 lines (27 loc) · 903 Bytes
/
Copy pathtests.bats
File metadata and controls
32 lines (27 loc) · 903 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
#!/usr/bin/env bats
setup() {
if command -v brew &> /dev/null; then
BREW_PREFIX="$(brew --prefix)"
load "${BREW_PREFIX}/lib/bats-support/load.bash"
load "${BREW_PREFIX}/lib/bats-assert/load.bash"
else
NPM_PREFIX="$(npm config get prefix)"
load "${NPM_PREFIX}/lib/node_modules/bats-support/load.bash"
load "${NPM_PREFIX}/lib/node_modules/bats-assert/load.bash"
fi
touch values.yaml
task run -- pre-commit
}
teardown() {
rm -f values.yaml
rm -f .pre-commit-config.yaml
}
@test "Generate helm values schema" {
pre-commit run --files values.yaml
pre-commit run --files values.yaml | grep 'Generate Helm values schema' | grep 'Passed'
assert_success
}
@test "Generate helm values documentation" {
pre-commit run --files values.yaml | grep 'Generate Helm values documentation' | grep Passed
assert_success
}