Class: Avm::EacRailsBase1::Sources::Base
- Inherits:
-
Avm::EacRubyBase1::Sources::Base
- Object
- Avm::EacRubyBase1::Sources::Base
- Avm::EacRailsBase1::Sources::Base
- Defined in:
- lib/avm/eac_rails_base1/sources/base.rb
Constant Summary collapse
- CONFIG_RU_SUBPATH =
'config.ru'
- EAC_RAILS_BASE1_TEST_NAME =
'eac_rails_base1'
- RAKE_TEST_COMMAND_DEFAULT_TASK_NAME =
'test'
- SUBS_PATHS_DEFAULT =
['sub/*/*'].freeze
Instance Method Summary collapse
- #config_ru_path ⇒ Object
- #default_test_commands ⇒ Object
- #eac_rails_base1_test_command ⇒ Object
- #rake_test_command(task_name = RAKE_TEST_COMMAND_DEFAULT_TASK_NAME) ⇒ Object
- #subs_paths_default ⇒ Object
- #valid? ⇒ Boolean
Instance Method Details
#config_ru_path ⇒ Object
15 16 17 |
# File 'lib/avm/eac_rails_base1/sources/base.rb', line 15 def config_ru_path path.join(CONFIG_RU_SUBPATH) end |
#default_test_commands ⇒ Object
19 20 21 22 23 |
# File 'lib/avm/eac_rails_base1/sources/base.rb', line 19 def default_test_commands { EAC_RAILS_BASE1_TEST_NAME => eac_rails_base1_test_command } end |
#eac_rails_base1_test_command ⇒ Object
25 26 27 |
# File 'lib/avm/eac_rails_base1/sources/base.rb', line 25 def eac_rails_base1_test_command rake_test_command end |
#rake_test_command(task_name = RAKE_TEST_COMMAND_DEFAULT_TASK_NAME) ⇒ Object
29 30 31 |
# File 'lib/avm/eac_rails_base1/sources/base.rb', line 29 def rake_test_command(task_name = RAKE_TEST_COMMAND_DEFAULT_TASK_NAME) rake(task_name).chdir_root.envvar('RAILS_ENV', 'test') end |
#subs_paths_default ⇒ Object
33 34 35 |
# File 'lib/avm/eac_rails_base1/sources/base.rb', line 33 def subs_paths_default SUBS_PATHS_DEFAULT end |
#valid? ⇒ Boolean
37 38 39 |
# File 'lib/avm/eac_rails_base1/sources/base.rb', line 37 def valid? super && config_ru_path.exist? end |