Skip to content
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

Fix plugin list smoke test #5946

Merged
merged 1 commit into from Mar 23, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 8 additions & 2 deletions test/artifact/inspec_plugin_test.rb
@@ -1,7 +1,13 @@
require_relative "artifact_helper"

class TestInspecPlugin < ArtifactTest
def test_plugin_lsit
assert_artifact("plugin list")
def test_plugin_list
# This one is custom because it emits a special warning to stderr
inspec_command = "plugin list"
stdout, stderr, status = run_cmd "inspec #{inspec_command} #{TEST_CLI_OPTS}"

assert_empty stderr.sub(/#< CLIXML\n/, "").sub(/The table size exceeds the currently set width\.Defaulting to vertical orientation\.\n/, "")
assert stdout
assert status
end
end