Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Tree: a26e237f91
Fetching contributors…

Cannot retrieve contributors at this time

22 lines (18 sloc) 0.505 kB
require 'spec_helper'
require 'parslet/rig/rspec'
describe Wt::Parser do
let(:parser) { described_class.new }
context "simple arithmetic expressions" do
subject { parser.expression }
it { should parse("1+2") }
it { should parse("1-2") }
it { should parse("1*2") }
it { should parse("1/2") }
it { should parse('1*2 + 3') }
it { should parse('1 * (1 + 3)') }
end
context "assignment" do
subject { parser.expression }
it { should parse('a = 1') }
end
end
Jump to Line
Something went wrong with that request. Please try again.