test/wolverine/script_test.rb in wolverine-0.2.0 vs test/wolverine/script_test.rb in wolverine-0.2.1
- old
+ new
@@ -23,11 +23,11 @@
script.instance_variable_set("@content", "asdfasdfasdf+31f")
script.instance_variable_set("@digest", "79437f5edda13f9c1669b978dd7a9066dd2059f1")
script.call(Redis.new)
rescue Wolverine::LuaCompilationError => e
assert_equal "'=' expected near '+'", e.message
- assert_equal "\tfrom e/file1.lua:1", e.backtrace.first
+ assert_equal "e/file1.lua:1", e.backtrace.first
end
end
def test_runtime_error
base = Pathname.new('/a/b/c/d')
@@ -38,13 +38,12 @@
script.instance_variable_set("@content", "return nil > 3")
script.instance_variable_set("@digest", "39437f5edda13f9c1669b978dd7a9066dd2059f1")
script.call(Redis.new)
rescue Wolverine::LuaRuntimeError => e
assert_equal "attempt to compare number with nil", e.message
- assert_equal "\tfrom e/file1.lua:1", e.backtrace.first
+ assert_equal "e/file1.lua:1", e.backtrace.first
end
end
-
def test_digest_and_content
content = "return 1"
assert_equal CONTENT, script.content
assert_equal DIGEST, script.digest