Sha256: d3a3894330a9b7a4f76d30b20e6e13d909613ade9dcd9ef2405e81103574b56d

Contents?: true

Size: 1.14 KB

Versions: 46

Compression:

Stored size: 1.14 KB

Contents

# ********** Copyright Viacom, Inc. Apache 2.0 **********

require_relative "test_helper.rb"

module RokuBuilder
  class PluginTest < Minitest::Test
    def setup
      Logger.set_testing
    end
    def test_module_commands_fail
      assert_raises ImplementationError do
        TestClass.commands
      end
    end
    def test_module_commands_success
      TestClass2.commands
    end
    def test_module_parse_options_fail
      assert_raises ImplementationError do
        TestClass.parse_options(option_parser: nil, options: nil)
      end
    end
    def test_module_parse_options_success
      TestClass2.parse_options(option_parser: nil, options: nil)
    end
    def test_module_dependencies
      assert_equal Array, TestClass.dependencies.class
    end
    def test_module_dependencies_dependent
      assert_equal Array, TestClass2.dependencies.class
      assert_equal TestClass, TestClass2.dependencies[0]
    end
  end
  class TestClass
    extend Plugin
  end
  class TestClass2
    extend Plugin
    def self.commands
    end
    def self.parse_options(option_parser:, options:)
    end
    def self.dependencies
      [TestClass]
    end
  end
end

Version data entries

46 entries across 46 versions & 1 rubygems

Version Path
roku_builder-4.15.2 test/roku_builder/test_plugin.rb
roku_builder-4.15.1 test/roku_builder/test_plugin.rb
roku_builder-4.15.0 test/roku_builder/test_plugin.rb
roku_builder-4.14.1 test/roku_builder/test_plugin.rb
roku_builder-4.14.0 test/roku_builder/test_plugin.rb
roku_builder-4.12.3 test/roku_builder/test_plugin.rb
roku_builder-4.13.0 test/roku_builder/test_plugin.rb
roku_builder-4.12.2 test/roku_builder/test_plugin.rb
roku_builder-4.12.1 test/roku_builder/test_plugin.rb
roku_builder-4.12.0 test/roku_builder/test_plugin.rb
roku_builder-4.11.5 test/roku_builder/test_plugin.rb
roku_builder-4.11.4 test/roku_builder/test_plugin.rb
roku_builder-4.11.3 test/roku_builder/test_plugin.rb
roku_builder-4.11.2 test/roku_builder/test_plugin.rb
roku_builder-4.11.1 test/roku_builder/test_plugin.rb
roku_builder-4.11.0 test/roku_builder/test_plugin.rb
roku_builder-4.10.1 test/roku_builder/test_plugin.rb
roku_builder-4.10.0 test/roku_builder/test_plugin.rb
roku_builder-4.9.5 test/roku_builder/test_plugin.rb
roku_builder-4.9.4 test/roku_builder/test_plugin.rb