spec/openstudio/excel_spec.rb in openstudio-analysis-1.0.0.rc9 vs spec/openstudio/excel_spec.rb in openstudio-analysis-1.0.0.rc10
- old
+ new
@@ -52,11 +52,11 @@
before(:all) do
@excel = OpenStudio::Analysis::Translator::Excel.new('spec/files/0_1_09_small_list_repeat_vars.xlsx')
end
it 'should fail to process' do
- expect { @excel.process }.to raise_error("duplicate variable names found in list [\"Insulation R-value (ft^2*h*R/Btu).\"]")
+ expect { @excel.process }.to raise_error('duplicate variable names found in list ["Insulation R-value (ft^2*h*R/Btu)."]')
end
end
context 'small list of variables should not validate' do
before(:all) do
@@ -441,12 +441,12 @@
expect(j['analysis']['output_variables'].first['display_name']).to eq 'Total Site Energy Intensity'
expect(j['analysis']['output_variables'].first['display_name_short']).to eq 'Site EUI'
expect(j['analysis']['problem']['workflow'][0]['variables'][0]['argument']['display_name']).to eq 'Orientation'
expect(j['analysis']['problem']['workflow'][0]['variables'][0]['argument']['display_name_short']).to eq 'Shorter Display Name'
- expect(j['analysis']['problem']['workflow'][1]['arguments'][0]['display_name']).to eq 'unknown'
- expect(j['analysis']['problem']['workflow'][1]['arguments'][0]['display_name_short']).to eq 'un'
+ expect(j['analysis']['problem']['workflow'][1]['arguments'][1]['display_name']).to eq 'unknown'
+ expect(j['analysis']['problem']['workflow'][1]['arguments'][1]['display_name_short']).to eq 'un'
end
end
context 'version 0.3.5 and measure paths' do
before :all do
@@ -483,10 +483,10 @@
expect(File.exist?('spec/files/export/analysis/0_3_7_worker_init_final.json')).to eq true
expect(File.exist?('spec/files/export/analysis/0_3_7_worker_init_final.zip')).to eq true
expect(@excel.worker_inits.size).to eq 2
expect(@excel.worker_inits[0][:name]).to eq 'initialize me'
- expect(@excel.worker_inits[0][:args]).to eq "[\"first_arg\",2,{a_hash: \"input\"}]"
+ expect(@excel.worker_inits[0][:args]).to eq '["first_arg",2,{a_hash: "input"}]'
# test the eval'ing of the args
a = eval(@excel.analysis.worker_inits.first[:metadata][:args])
expect(a[0]).to eq 'first_arg'
expect(a[1]).to eq 2