-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add workflows for property-based testing
- Loading branch information
Showing
7 changed files
with
44 additions
and
19 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -8,3 +8,6 @@ do | |
echo "Running tests in: $tb" | ||
$tb | ||
done | ||
|
||
# Always exit successfully so that the test job isn't restarted | ||
exit 0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
#!/bin/bash | ||
|
||
# Delete the tests job | ||
yq " | ||
.metadata.namespace = \"keramik-$1$TEST_SUFFIX\" | | ||
(select(.subjects[] | length) | .subjects[0].namespace) = \"keramik-$1$TEST_SUFFIX\" | ||
" ../manifests/setup.yaml | kubectl delete -f - | ||
|
||
# Delete the test network | ||
yq ".metadata.name = \"$1$TEST_SUFFIX\"" ../../networks/"$1".yaml | kubectl delete -f - | ||
|
||
# Wait for namespace to get deleted | ||
kubectl wait --for=delete namespace/"keramik-$1$TEST_SUFFIX" --timeout=10m |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
#!/bin/bash | ||
|
||
# Create namespace and setup RBAC | ||
kubectl create namespace "keramik-$1$TEST_SUFFIX" | ||
yq " | ||
.metadata.namespace = \"keramik-$1$TEST_SUFFIX\" | | ||
(select(.subjects[] | length) | .subjects[0].namespace) = \"keramik-$1$TEST_SUFFIX\" | ||
" ../manifests/setup.yaml | kubectl apply -f - | ||
|
||
# Create the network. | ||
kubectl create configmap check-network --from-file=check-network.sh -n "keramik-$1$TEST_SUFFIX" | ||
yq ".metadata.name = \"keramik-$1$TEST_SUFFIX\"" ../../networks/"$1".yaml | kubectl apply -f - | ||
|
||
# Create the test job | ||
kubectl apply -f ../manifests/tests.yaml -n "keramik-$1$TEST_SUFFIX" | ||
|
||
# Wait for tests to complete |