Rubyで行の下の意味を知りたいだけなので、私の質問がばかげている場合は申し訳ありません。(私はコースのために Rails に関する本をできるだけ早く読んでいるので、Ruby 言語をしっかりと把握していません。)
単体テスト用のコードは次のとおりです。
class ProductTest < ActiveSupport::TestCase
test "product attributes must not be empty" do // this line I don't know
product = Product.new
assert product.invalid?
assert product.errors[:title].any?
assert product.errors[:description].any?
assert product.errors[:price].any?
assert product.errors[:image_url].any?
end
私が聞きたいのは、私が知らない行で、構文 test "...." do
、それはどういう意味ですか? 関数、メソッド、クラス、その他の何かですか?