spec/d-mark/parser_spec.rb in d-mark-1.0.0b1 vs spec/d-mark/parser_spec.rb in d-mark-1.0.0b2
- old
+ new
@@ -1,19 +1,17 @@
-def parse(s)
- DMark::Parser.new(s).parse
+def parse(str)
+ DMark::Parser.new(str).parse
end
def element(name, attributes, children)
DMark::ElementNode.new(name, attributes, children)
end
describe DMark::Parser::ParserError do
subject(:error) do
- begin
- DMark::Parser.new(content).parse
- rescue described_class => e
- break e
- end
+ DMark::Parser.new(content).parse
+ rescue described_class => e
+ break e
end
let(:content) do
"#p Stuff\n\n#p More stuff }"
end