diff --git a/spec/factories/employee_factory.rb b/spec/factories/employee_factory.rb index afddfef7..b68fe238 100644 --- a/spec/factories/employee_factory.rb +++ b/spec/factories/employee_factory.rb @@ -2,7 +2,7 @@ FactoryBot.define do factory :employee do sequence(:name){|i| "Employee #{i}"} sequence(:email){ |i| "employee#{i}@mozo.bar" } - password 'secret' + password { 'secret' } trait :confirmed do #confirmed_at { Time.now } diff --git a/spec/factories/order_factory.rb b/spec/factories/order_factory.rb index 72843cd2..6747e905 100644 --- a/spec/factories/order_factory.rb +++ b/spec/factories/order_factory.rb @@ -4,13 +4,13 @@ FactoryBot.define do association :user association :supplier #TODO warning! this may create a different supplier than the one created by the associated table trait :placed do - state 'placed' + state { 'placed' } end trait :active do - state 'active' + state { 'active' } end trait :cancelled do - state 'cancelled' + state { 'cancelled' } end end end diff --git a/spec/factories/page_factory.rb b/spec/factories/page_factory.rb index 01f09cc8..a0ae27e4 100644 --- a/spec/factories/page_factory.rb +++ b/spec/factories/page_factory.rb @@ -1,6 +1,6 @@ FactoryBot.define do factory :page do - locale 'en' - layout 'theme1' + locale { 'en' } + layout { 'theme1' } end end diff --git a/spec/factories/product_factory.rb b/spec/factories/product_factory.rb index 95c77b77..21009c1e 100644 --- a/spec/factories/product_factory.rb +++ b/spec/factories/product_factory.rb @@ -1,7 +1,7 @@ FactoryBot.define do factory :product do sequence(:name){|i| "Product#{i}"} - price 34.95 + price { 34.95 } association :supplier end end diff --git a/spec/factories/product_order_factory.rb b/spec/factories/product_order_factory.rb index 2f37400e..ef0f4c2b 100644 --- a/spec/factories/product_order_factory.rb +++ b/spec/factories/product_order_factory.rb @@ -1,6 +1,6 @@ FactoryBot.define do factory :product_order do - quantity 1 + quantity { 1 } association :order association :product end diff --git a/spec/factories/supplier_factory.rb b/spec/factories/supplier_factory.rb index 90369602..ff315503 100644 --- a/spec/factories/supplier_factory.rb +++ b/spec/factories/supplier_factory.rb @@ -2,7 +2,7 @@ FactoryBot.define do factory :supplier do sequence(:name){|i| "Supplier #{i}"} trait :open do - open true + open { true } end end end diff --git a/spec/factories/table_factory.rb b/spec/factories/table_factory.rb index b8effcfd..a1329ea6 100644 --- a/spec/factories/table_factory.rb +++ b/spec/factories/table_factory.rb @@ -1,6 +1,6 @@ FactoryBot.define do factory :table do - number 22 + number { 22 } association :supplier end end diff --git a/spec/factories/user_factory.rb b/spec/factories/user_factory.rb index 00361bb5..4e48a94c 100644 --- a/spec/factories/user_factory.rb +++ b/spec/factories/user_factory.rb @@ -1,11 +1,11 @@ FactoryBot.define do factory :user do sequence( :email ){|i| "test#{i}@example.com" } - password "secret" + password { "secret" } trait :other_auth do sequence( :email ){|i| "test-other-user#{i}@example.com" } - auth_data( { + auth_data {{ 'info' => { 'nickname' => "UOther", "name" => "USR Other", @@ -15,7 +15,7 @@ FactoryBot.define do "token" => "fbAuthToken234", 'expires' => false } - }) + }} end end end