LoginSignup
0
0

More than 1 year has passed since last update.

Rails impressionist gemについての問題

Posted at

使用環境

rails 6

問題点

作成したアプリにimpressionist gemを導入して、テストコードを組んだのですが、
NoMethodError:
undefined method `cookie_value' for nil:NilClass
というエラーが出力されてしまう。

改善内容

色々と調べていくとver2.0にそういうエラーがあり、古いバージョンか改修したものを
インストールしないと改善できないみたいです。

gem 'impressionist', '~>1.6.1'

バージョンを指定して、bundle installし直すと、エラーは出力されなくなりました!
rails 6は最新のバージョンを

まとめ

GitHubやGemの説明文はしっかりと読んで、参考にしましょう。

参照

https://github.com/charlotte-ruby/impressionist
https://stackoverflow.com/questions/64969386/undefined-method-cookie-value-for-impressionist-gem

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0