Module: StartHer::Testing
- Defined in:
- lib/start_her/testing.rb
Class Method Summary collapse
-
.__set_test_mode(mode) ⇒ Object
rubocop:disable Style/TrivialAccessors.
-
.clear_stubed_redis ⇒ Object
rubocop:disable Style/GlobalVars.
-
.disable! ⇒ Object
rubocop:enable Style/TrivialAccessors.
- .disable? ⇒ Boolean
- .fake! ⇒ Object
- .fake? ⇒ Boolean
Class Method Details
.__set_test_mode(mode) ⇒ Object
rubocop:disable Style/TrivialAccessors
14 15 16 |
# File 'lib/start_her/testing.rb', line 14 def __set_test_mode(mode) @__test_mode = mode end |
.clear_stubed_redis ⇒ Object
rubocop:disable Style/GlobalVars
8 9 10 |
# File 'lib/start_her/testing.rb', line 8 def clear_stubed_redis $stubed_redis.clear_db if $stubed_redis end |
.disable! ⇒ Object
rubocop:enable Style/TrivialAccessors
19 20 21 |
# File 'lib/start_her/testing.rb', line 19 def disable! __set_test_mode(:disable) end |
.disable? ⇒ Boolean
27 28 29 |
# File 'lib/start_her/testing.rb', line 27 def disable? @__test_mode == :disable end |
.fake! ⇒ Object
23 24 25 |
# File 'lib/start_her/testing.rb', line 23 def fake! __set_test_mode(:fake) end |
.fake? ⇒ Boolean
31 32 33 |
# File 'lib/start_her/testing.rb', line 31 def fake? @__test_mode == :fake end |