gem "minitest" require 'minitest/spec' require "minitest/autorun" require "svelte" class TestSvelte < Minitest::Test def setup @files = File.join(File.expand_path(File.dirname(__FILE__)), "files") @hello_world_filename = File.join(@files, 'hello_world.html') @hello_world_output = IO.read(File.join(@files, 'hello_world_output.txt')) @hello_world_output_iife = IO.read(File.join(@files, 'hello_world_output_iife.txt')) end def test_version exp = "1.12.1" act = Svelte.exec_eval('svelte.VERSION') assert_equal exp, act end def test_compile_with_string exp = @hello_world_output act = Svelte.exec_method('svelte.compile', '