diff options
Diffstat (limited to 'spec')
| -rw-r--r-- | spec/exporters/chouette/kml/exporter_spec.rb | 3 | ||||
| -rw-r--r-- | spec/factories.rb | 4 |
2 files changed, 6 insertions, 1 deletions
diff --git a/spec/exporters/chouette/kml/exporter_spec.rb b/spec/exporters/chouette/kml/exporter_spec.rb index 53e485cd7..dd7c44327 100644 --- a/spec/exporters/chouette/kml/exporter_spec.rb +++ b/spec/exporters/chouette/kml/exporter_spec.rb @@ -10,7 +10,8 @@ describe Chouette::Kml::Exporter do # referential.switch # Factory(:line_with_stop_areas_having_parent) } - subject { Chouette::Kml::Exporter.new(first_referential) } + let(:kml_export){ Factory(:kml_export)} + subject { Chouette::Kml::Exporter.new(first_referential, kml_export) } let(:tmp_path) { File.join( Rails.root, "tmp")} let(:exports_path) { File.join( tmp_path, "exports")} diff --git a/spec/factories.rb b/spec/factories.rb index 7ae087de0..681400443 100644 --- a/spec/factories.rb +++ b/spec/factories.rb @@ -31,6 +31,10 @@ FactoryGirl.define do f.sequence(:key) { "key_#{n}" } end + factory :kml_export do |f| + f.referential { Referential.find_by_slug("first") } + end + factory :export do |f| f.referential { Referential.find_by_slug("first") } end |
