Sha256: 335c4e8eba53b8c759d7247abf6ec9b05f30f262f744f9b3c2212544c376307a
Contents?: true
Size: 713 Bytes
Versions: 35
Compression:
Stored size: 713 Bytes
Contents
require "spec_helper" require "expressir/express_exp/parser" require "expressir/express_exp/formatter" RSpec.describe Expressir::ExpressExp::Formatter do describe ".format" do it "formats syntax" do repo = Expressir::ExpressExp::Parser.from_file(input_file) result = Expressir::ExpressExp::Formatter.format(repo) expected_result = File.read(output_file) expect(result).to eq(expected_result) end end def input_file @input_file ||= Expressir.root_path.join( "original", "examples", "syntax", "syntax.exp" ) end def output_file @output_file ||= Expressir.root_path.join( "original", "examples", "syntax", "syntax_formatted.exp" ) end end
Version data entries
35 entries across 35 versions & 1 rubygems