diff options
| author | Luc Donnet | 2018-03-30 10:22:26 +0200 | 
|---|---|---|
| committer | Luc Donnet | 2018-03-30 10:22:26 +0200 | 
| commit | ddf9807fd2e5e0ec26011051f63fda87c6c1f2f6 (patch) | |
| tree | 212d224aad9481acf538ecd2794a04f04204323d /spec/support | |
| parent | afbe88e752f3c5e7eadfcf1ab53c740b60334779 (diff) | |
| download | chouette-core-ddf9807fd2e5e0ec26011051f63fda87c6c1f2f6.tar.bz2 | |
Fix spec/features/calendars_permissions_spec.rb to use correct Workgroup Refs #6258 @1
Diffstat (limited to 'spec/support')
| -rw-r--r-- | spec/support/referential.rb | 12 | 
1 files changed, 12 insertions, 0 deletions
| diff --git a/spec/support/referential.rb b/spec/support/referential.rb index 9acdce73a..b50844ae4 100644 --- a/spec/support/referential.rb +++ b/spec/support/referential.rb @@ -8,6 +8,10 @@ module ReferentialHelper      Organisation.find_by!(code: "first")    end +  def first_workgroup +    Workgroup.find_by_name('IDFM') +  end +    def self.included(base)      base.class_eval do        extend ClassMethods @@ -53,10 +57,18 @@ RSpec.configure do |config|        referential.add_member organisation, owner: true      end +    workgroup = FactoryGirl.create( +      :workgroup, +      name: "IDFM", +      line_referential: line_referential, +      stop_area_referential: stop_area_referential +    ) +      workbench = FactoryGirl.create(        :workbench,        name: "Gestion de l'offre",        organisation: organisation, +      workgroup: workgroup,        line_referential: line_referential,        stop_area_referential: stop_area_referential      ) | 
