mirror of
https://github.com/inspec/inspec
synced 2024-12-26 21:13:25 +00:00
21 lines
940 B
Ruby
21 lines
940 B
Ruby
|
require_relative '../../../shared/core_plugin_test_helper.rb'
|
||
|
|
||
|
#-----------------------------------------------------------------------#
|
||
|
# Plugin Definition
|
||
|
#-----------------------------------------------------------------------#
|
||
|
class PluginManagerCliDefinitionTests < MiniTest::Test
|
||
|
include CorePluginUnitHelper
|
||
|
|
||
|
def test_plugin_registered
|
||
|
loader = Inspec::Plugin::V2::Loader.new
|
||
|
loader.load_all # We want to ensure it is auto-loaded
|
||
|
|
||
|
assert registry.known_plugin?(:'inspec-plugin-manager-cli'), 'inspec-plugin-manager-cli should be registered'
|
||
|
assert registry.loaded_plugin?(:'inspec-plugin-manager-cli'), 'inspec-plugin-manager-cli should be loaded'
|
||
|
|
||
|
status = registry[:'inspec-plugin-manager-cli']
|
||
|
assert_equal 2, status.api_generation, 'inspec-plugin-manager-cli should be v2'
|
||
|
assert_includes status.plugin_types, :cli_command, 'inspec-plugin-manager-cli should have cli_command activators'
|
||
|
end
|
||
|
end
|