每次我做rake测试我得到12个错误都有相同的错误
8)错误:ProductTest#test_image_url:ActiveRecord :: Fixture :: FormatError:ActiveRecord :: Fixture :: FormatError
9)错误:ProductTest#test_product_attributes_must_not_be_empty:ActiveRecord :: Fixture :: FormatError:ActiveRecord :: Fixture :: FormatError
10)错误:ProductTest #test_product_is_not_valid_without_a_unique_title:ActiveRecord :: Fixture :: FormatError:ActiveRecord :: Fixture :: FormatError
11)错误:ProductTest#test_product_is_not_valid_without_a_unique_title _-_ i18n:ActiveRecord :: Fixture :: FormatError:ActiveRecord :: Fixture :: FormatError
12)错误:ProductTest#test_product_price_must_be_positive:ActiveRecord :: Fixture :: FormatError:ActiveRecord :: Fixture :: FormatError
第一行是:
syntax error, unexpected ( arg, expecting keyword_do or '{' or '('
post :create, product_id: products (:ruby).id
Run Code Online (Sandbox Code Playgroud)
这是我的yaml文件
one:
title: MyString
description: MyText
image_url: MyString
price: 9.99
two:
title: MyString
description: …Run Code Online (Sandbox Code Playgroud)