Sha256: e04435581439e767d95ee2ff74a5b0f6f0820f8e81593aefc4cd1efa8030462e

Contents?: true

Size: 789 Bytes

Versions: 10

Compression:

Stored size: 789 Bytes

Contents

require File.expand_path(File.join(File.dirname(__FILE__), "/../../helper"))

require 'stringio'

module Johnson
  module TraceMonkey
    class ImmutableNodeTest < Johnson::TestCase
      include Johnson::TraceMonkey

      def test_initialize
        node = nil
        assert_nothing_raised {
          node = ImmutableNode.new
        }
      end

      def test_parse_some_shit
        assert_nothing_raised {
          node = ImmutableNode.parse_io(StringIO.new('var x = 10;'))
        }
      end

      def test_index
        node = ImmutableNode.parse_io(StringIO.new('var x = 10;'))
        assert_equal(0, node.index)
      end

      def test_line
        node = ImmutableNode.parse_io(StringIO.new('var x = 10;'))
        assert_equal(0, node.line)
      end
    end
  end
end

Version data entries

10 entries across 10 versions & 4 rubygems

Version Path
johnson19-2.0.0.pre3 test/johnson/tracemonkey/immutable_node_test.rb
pre-johnson-2.0.0 test/johnson/tracemonkey/immutable_node_test.rb
johnson-2.0.0.pre3 test/johnson/tracemonkey/immutable_node_test.rb
johnson-2.0.0.pre2 test/johnson/tracemonkey/immutable_node_test.rb
johnson-2.0.0.pre1 test/johnson/tracemonkey/immutable_node_test.rb
johnson-2.0.0.pre0 test/johnson/tracemonkey/immutable_node_test.rb
smparkes-johnson-1.1.2.6 test/johnson/tracemonkey/immutable_node_test.rb
smparkes-johnson-1.1.2.5 test/johnson/tracemonkey/immutable_node_test.rb
smparkes-johnson-1.1.2.4 test/johnson/tracemonkey/immutable_node_test.rb
smparkes-johnson-1.1.2.3 test/johnson/tracemonkey/immutable_node_test.rb