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
34 35 36 37 38 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 34 def assert(ENV.key?(TEST_MESSAGE_KEY)) = ENV[TEST_MESSAGE_KEY] assert_equal(, TEST_MESSAGE_VALUE) end |
#test_plugin_name_key ⇒ Object
15 16 17 18 19 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 15 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
21 22 23 24 25 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 21 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
27 28 29 30 31 32 |
# File 'lib/repla/test/packages/TestEnvironment.replaplugin/Contents/Resources/test_environment.rb', line 27 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 |