File: test_parser_hard.rb

package info (click to toggle)
ruby-toml 0.1.1-1
  • links: PTS, VCS
  • area: main
  • in suites: jessie, jessie-kfreebsd
  • size: 216 kB
  • ctags: 105
  • sloc: ruby: 518; sh: 3; makefile: 2
file content (15 lines) | stat: -rw-r--r-- 406 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
require 'multi_json'
require 'toml'
require 'minitest/autorun'

class TestParserHardExample < MiniTest::Test
  def setup
    filepath = File.join(File.dirname(__FILE__), 'hard_example.toml')
    # @doc = TOML::Parser.new(File.read(filepath)).parsed
    @doc = TOML.load_file(filepath)
  end

  def test_the_test_string
    assert_equal @doc["the"]["test_string"], "You'll hate me after this - #"
  end
end