Permalink
Browse files

[CS] Remove spec duplication

  • Loading branch information...
1 parent 8cf52fc commit ab25a8ba4eaf93532016cf341745c09f2ed0c320 @benlangfeld benlangfeld committed Oct 11, 2012
Showing with 4 additions and 8 deletions.
  1. +4 −8 spec/ruby_speech/nlsml_spec.rb
@@ -83,6 +83,8 @@
RubySpeech.parse example_document
end
+ let(:empty_result) { '<result xmlns:xf="http://www.w3.org/2000/xforms"/>' }
+
its(:grammar) { should == 'http://flight' }
it { should be_match }
@@ -114,18 +116,12 @@
end
it "should not be equal if the XML is different" do
- subject.should_not be == RubySpeech.parse('<result xmlns:xf="http://www.w3.org/2000/xforms" grammar="http://flight"/>')
+ subject.should_not be == RubySpeech.parse(empty_result)
end
context "without any interpretations" do
- let :doc_without_interpretations do
- '''
-<result xmlns:xf="http://www.w3.org/2000/xforms" grammar="http://flight"/>
- '''
- end
-
subject do
- RubySpeech.parse doc_without_interpretations
+ RubySpeech.parse empty_result
end
it { should_not be_match }

0 comments on commit ab25a8b

Please sign in to comment.