-
Notifications
You must be signed in to change notification settings - Fork 682
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failing tests in inherited tests are not displayed #899
Comments
nvtkaszpir
changed the title
Failing tests in interited tests are not displayed
Failing tests in inherited tests are not displayed
Aug 27, 2016
The issue persists after upgrade to 0.32.0: When using included profile, it is still hidden, but failure is marked in the footer:
When executed test directly, it is well visible:
|
@nvtkaszpir do you see that with the latest 0.35.0 still? |
The error no longer exists on inspec 0.35.0. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
Detected when reporting #898
Executed profile directly, it fails as it should.
The same profile if is inherited then it is shown as failed in the summary section, but not during import.
InSpec and Platform Version
Replication Case
inspec/default-jdk - it has two tests in one control block (showing only test file):
inspec/profiles/xstream-jmeter-slave (showing only test file):
Testing default-jdk directly - it does not show the passed test that package is installed, but it shows eror that package version is wrong:
Testing profile inheritance - now it shows that control block is 'green' even though it fails:
Digging deeper
Moving test int separate 'describe' within the same control is not enough:
Directly executed profile shows only specific failure within control block:
Inherited profile still shows the same odd behavior:
Possible Solutions
Move tests into even more granular controls - with one 'describe' per control block.
Moving test int separate 'describe' within the same control is not enough.
Of course we could write test to just check if package version is valid (and ditch the test part if package is installed).
First, split test in default-jdk into separated sections, if package is installed, if package version is correct
Test it - now each test is presented as it should, no missing 'pacpakge should be installed':
Now, let execute inherited profile again - the failing test is not hidden anymore:
Stacktrace
No stack trace.
The text was updated successfully, but these errors were encountered: