Sha256: d8933933cfa49e04cf7d8643d1493d2b602b70cbe5d78875715a6e7396c1219b
Contents?: true
Size: 912 Bytes
Versions: 5
Compression:
Stored size: 912 Bytes
Contents
require File.expand_path(File.join(File.dirname(__FILE__), '..', 'lib', 'rflow')) require 'fileutils' require 'log4r' require 'rspec/collection_matchers' require 'tmpdir' I18n.enforce_available_locales = true RSpec.configure do |config| config.before(:all) do RFlow.logger = Log4r::Logger.new 'test' RFlow.logger.add Log4r::StdoutOutputter.new('test_stdout', :formatter => RFlow::Logger::LOG_PATTERN_FORMATTER) RFlow.logger.level = 5 end config.before(:each) do @temp_directory_path = Dir.mktmpdir('rflow') end config.after(:each) do FileUtils.rm_rf @temp_directory_path end end def decode_avro(schema_string, bytes) schema = Avro::Schema.parse(schema_string) RFlow::Avro.decode(Avro::IO::DatumReader.new(schema, schema), bytes) end def encode_avro(schema_string, message) RFlow::Avro.encode(Avro::IO::DatumWriter.new(Avro::Schema.parse(schema_string)), message) end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
rflow-1.0.0 | spec/spec_helper.rb |
rflow-1.0.0a6 | spec/spec_helper.rb |
rflow-1.0.0a5 | spec/spec_helper.rb |
rflow-1.0.0a4 | spec/spec_helper.rb |
rflow-1.0.0a3 | spec/spec_helper.rb |