Migrate acceptance tests to rspec (#1513)

Move existing tests executed with the help of bats to use rspec directly
combined with tags to filter them out from being executed by default.

This allows for more complex assertions as well as easier debug as the
code supports use of setting 'VAGRANT_SPEC_SKIP_CLEANUP' to prevent the
tests from removing the temporary directory created for home and work
directories.

Extend a number of classes from vagrant-spec to override default
behaviour to allow passing of additional environment variables for
packaging tests, as well as supporting the skip cleanup. Given the use
of after to perform the cleanup, need to vendor the vagrant-spec
acceptance context in order to modify it easily.
This commit is contained in:
Darragh Bailey
2022-06-13 23:43:06 +01:00
committed by GitHub
parent 66e0fa7dda
commit 41bd20269e
31 changed files with 546 additions and 350 deletions

4
.gitignore vendored
View File

@@ -16,9 +16,7 @@ spec/reports
test/tmp
test/version_tmp
tmp
Vagrantfile
!tests/*/Vagrantfile
!example_box/Vagrantfile
/Vagrantfile
.vagrant
*.swp
.deps