-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tests: Enable Acceptance Tests (#103)
Enable acceptance tests and fix existing tests. 1) Enable running acceptance tests on `make test` command when the user places a kubeconfig file into the repository. This kubeconfig is necessary since the acceptance tests are checked against a real Harvester cluster. If the kubeconfig file is missing, only unit tests are run, which doesn't require a Harvester cluster. 2) Fix existing tests. Some existing acceptance tests where using invalid terraform resources. These are fixed 3) Fix volume and network resource providers. Running acceptance tests revealed bugs in the volume and network resource providers. Both were using an incorrect method to determine if a resource had been deleted in Harvester. The bug was that the resource providers were waiting for a deletion event, despite the fact that the respective controllers don't emit such an event. The fix is to observe the resource through a periodic read. 4) Fix propagating the cluster network name of a network resource into the terraform state. The terraform state needs to keep track of this property to determine if the resource definition has changed. Otherwise the resource will always count as modified, which is in some cases wrong. This bug was also revealed by the acceptance tests. Signed-off-by: Moritz Röhrich <moritz.rohrich@suse.com>
- Loading branch information
1 parent
45fde4b
commit 55ee9e6
Showing
9 changed files
with
122 additions
and
38 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
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 |
---|---|---|
|
@@ -24,6 +24,8 @@ const ( | |
resource %s "%s" { | ||
%s = "%s" | ||
%s = "%s" | ||
parameters = { | ||
} | ||
} | ||
` | ||
) | ||
|
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 |
---|---|---|
|
@@ -3,7 +3,7 @@ set -e | |
|
||
cd $(dirname $0) | ||
|
||
./validate | ||
./build | ||
./test | ||
./validate | ||
./package |
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 |
---|---|---|
|
@@ -3,7 +3,4 @@ set -e | |
|
||
cd $(dirname $0) | ||
|
||
./build | ||
./test | ||
./validate | ||
./package | ||
./ci |
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