Module: ConfigHelper
- Included in:
- ActionHelper, SuperTest
- Defined in:
- lib/common/myconf_helper.rb
Overview
读取配置,配置文件以YAML的格式进行存储
提供环境切换机制,如下
#读取sz00.yml env: sz00
Constant Summary collapse
- CONF =
YAML.load_file "#{$SUPER_ROOT}/conf/super_test.yml"
- ENV =
环境相关的配置
ENV.to_hash.merge YAML.load_file("#{$SUPER_ROOT}/conf/#{CONF['env']}.yml")