Save_and_open_page 未拾取 scss 标记
刚刚将 RoR 3.0 项目升级到 3.2。我已将 CSS 资产移至资产管道,现在使用 SASS。我的 Rspec 请求规范仍然通过,但是当我放入 save_and_open_page 语句时,生成的页面没有任何 CSS 样式。 HTML 渲染完全准确,说明已通过测试。
有什么配置想法吗?
Just upgraded a RoR 3.0 project to 3.2. I've moved the CSS assets to the asset pipeline and now using SASS. My Rspec request specs still pass, but when I throw in a save_and_open_page statement, the resulting page doesn't have any CSS stylings. The HTML rendering is all accurate, explaining the passing tests.
Any config ideas?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以使用 capybara-screenshot gem 进行调试。
它将截取您要调试的页面的屏幕截图。
安装 gem 并使用
screen_shot_and_open_image
而不是save_and_open_page
You can use
capybara-screenshot
gem for debugging.It will take a screenshot of the page you want to debug.
Install the gem and use
screen_shot_and_open_image
instead ofsave_and_open_page