Sha256: c07baa1d5ee3c0c769184b2d9da0b62126bb94d958273da23f0e48e0e62d0506
Contents?: true
Size: 1.37 KB
Versions: 11
Compression:
Stored size: 1.37 KB
Contents
# encoding: utf-8 require 'spec_helper' require 'fedux_org_stdlib/gem_plugins/plugin_manager' RSpec.describe GemPlugins::PluginManager do context '#load_plugins' do it 'loads available plugins' do manager = GemPlugins::PluginManager.new prefix: 'fedux_org_stdlib-fixtures-plugin_manager-' manager.disable_plugin 'plugin-no_load' manager.load_plugins expect('FeduxOrgStdlib::Fixtures::PluginManager::Plugin::Load').to be_defined end end context '#disable' do it 'disable plugin' do manager = GemPlugins::PluginManager.new prefix: 'fedux_org_stdlib-fixtures-plugin_manager-' manager.disable_plugin 'plugin-no_load' manager.load_plugins expect('FeduxOrgStdlib::Fixtures::PluginManager::Plugin::NoLoad').not_to be_defined end it 'outputs warning if plugin cannout be found' do manager = GemPlugins::PluginManager.new prefix: 'fedux_org_stdlib-fixtures-plugin_manager-' result = capture :stderr do manager.disable_plugin 'plugin-blub' end expect(result).to include 'plugin-blub' end end context '#to_s' do it 'has a string representation' do manager = GemPlugins::PluginManager.new prefix: 'fedux_org_stdlib-fixtures-plugin_manager-' manager.disable_plugin 'plugin-no_load' manager.load_plugins expect(manager.to_s).to include 'plugin' end end end
Version data entries
11 entries across 11 versions & 1 rubygems