Check the responses and make sure we dont blindly return eg: size=0 or group="" or user="" for files that dont exist.
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
Only return nil for no content on specinfra files if the file actually has any content. ie. when we were not able to read the content then provide the answer of nil. if the file has no content, return an empty string. this leaves the error case where empty files cannot be read, which will not be signaled via content from specinfra.
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
For now: Since stat throws exit code 1 on selinux label checks if no selinux label (or system) is present, it would signal us to disregard results. However, the results are actually complete and can be fully used, with selinux_label becoming "?".
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
By default it uses the currently running OS on initialization, instead of the OS configured via backend. Force its reinitialization by resetting all properties.
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
Take control of the rspec runner loop and make sure all of our concurrent tests are executed in one reporting chain. It goes: Start reporting, concurrently run container+test+kill, stop and publish reporting.
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
With just one more issue left: the formatter is going to report multiple time, including spitting out errors multiple times. Also need to remove some of the custom formatting around the current state of containers.
As a bonus: This further improved testing speed (30% on the current environment) and will allow us to grow the supported platforms for tests easily.
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>
Instead of having RSpec re-run its world multiple times, run it only once with all tests.
Which leaves us with one more thing to solve: we want to start tests as soon as the container is up and they are set up. At the moment, the containers come up and are set up concurrently, including test registry, but the tests themselves are in simple sequence.
Signed-off-by: Dominik Richter <dominik.richter@gmail.com>