Class: TestEnviroment
- Inherits:
-
Test::Unit::TestCase
- Object
- Test::Unit::TestCase
- TestEnviroment
- Defined in:
- lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb
Overview
Test environment
Instance Method Summary collapse
- #test_message_key ⇒ Object
- #test_plugin_name_key ⇒ Object
- #test_split_id_key ⇒ Object
- #test_window_id_key ⇒ Object
Instance Method Details
#test_message_key ⇒ Object
31 32 33 34 35 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 31 def assert(ENV.key?(TEST_MESSAGE_KEY)) = ENV[TEST_MESSAGE_KEY] assert_equal(, TEST_MESSAGE_VALUE) end |
#test_plugin_name_key ⇒ Object
12 13 14 15 16 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 12 def test_plugin_name_key assert(ENV.key?(Repla::PLUGIN_NAME_KEY)) plugin_name = ENV[Repla::PLUGIN_NAME_KEY] assert_equal(plugin_name, TEST_PLUGIN_NAME) end |
#test_split_id_key ⇒ Object
18 19 20 21 22 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 18 def test_split_id_key assert(ENV.key?(Repla::SPLIT_ID_KEY)) window_id = ENV[Repla::SPLIT_ID_KEY] assert(!window_id.integer?) end |
#test_window_id_key ⇒ Object
24 25 26 27 28 29 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 24 def test_window_id_key assert(ENV.key?(Repla::WINDOW_ID_KEY)) window_id = ENV[Repla::WINDOW_ID_KEY] assert(window_id.integer?) assert(window_id.to_i > 0) end |