Sha256: 497e794ef367c8b5e57f987a276b6bc5939ddf11c76c44be1dd16937f99b3cf1

Contents?: true

Size: 472 Bytes

Versions: 3

Compression:

Stored size: 472 Bytes

Contents

require 'test_helper'
 
class TestExampleApp < Test::Unit::TestCase

	include TestHelper
	include CodeModels
	include CodeModels::Js

	def setup
		@root = Js.parse_file(relative_path('data/app.js'))
	end

	def test_root_is_ast_root
		assert_class AstRoot, @root
	end

	def test_root_contains_function_call
		assert_equal 1, @root.statements.count
		assert_class ExpressionStatement, @root.statements[0]
		assert_class FunctionCall, @root.statements[0].expression
	end

end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
codemodels-js-0.1.1-java test/test_example_app.rb
codemodels-js-0.1.0-java test/test_example_app.rb
codemodels-js-0.1.0 test/test_example_app.rb