Sha256: 6b4fde90cd5eee3f7993aed05e0495ffe27399d40eba3e5db7863c776bc3a775
Contents?: true
Size: 1 KB
Versions: 8
Compression:
Stored size: 1 KB
Contents
require File.expand_path( File.dirname(__FILE__) + '/../../../spec_helper' ) require 'spec_id/precision/filter' require 'spec_id/precision/filter/output' describe 'transforming hash with symbols into strings' do it 'works' do hash = {:one=>2, :this=>{:one=>"string", 3=>{:four=>5}}} new_hash = SpecID::Precision::Output.symbol_keys_to_string(hash) new_hash.should == {'one'=>2, 'this'=>{'one'=>"string", 3=>{'four'=>5}}} end end describe 'outputs' do before(:each) do @file = Tfiles + '/bioworks_with_INV_small.xml' @opts = {} end it 'makes a table' do my_file = Tfiles + '/filtering_tmp.tmp' File.unlink my_file if File.exist? my_file @opts[:output] = [[:text_table, my_file]] SpecID::Precision::Filter.new.filter_and_validate(SpecID.new(@file), @opts) #reply = capture_stdout { # SpecID::Precision::Filter.new.filter_and_validate(SpecID.new(@file), @opts) #} # frozen IO.read(my_file) =~ /138/ File.unlink my_file if File.exist? my_file end end
Version data entries
8 entries across 8 versions & 1 rubygems