File: test_helper.rb

package info (click to toggle)
ruby-ogginfo 0.7.2-3
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 252 kB
  • sloc: ruby: 2,010; makefile: 8
file content (11 lines) | stat: -rw-r--r-- 314 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
require "yaml"
require "tempfile"

def load_fixtures
  fixtures = YAML::load_file(File.join(File.dirname(__FILE__), "fixtures.yml"))
  fixtures.each_with_object({}) do |(codec, content), hash|
    f = File.join(Dir.tmpdir, "/test.ruby-ogginfo.#{codec}")
    File.binwrite(f, content)
    hash[codec] = f
  end
end