阅读背景:

Ruby on Rails:在不影响数据库的情况下测试ActiveRecord的方法?

来源:互联网 

I am using Ruby on Rails 2.3.8. I have several User model objects stored in memory and several Where conditions that I want to check these against. Because all this data is stored in memory I want to avoid hitting the database to perform these checks. Is there a way to check these models without hitting the database, i.e. some way to validate a SQL Where condition against an in-memory model object? I am using Ruby on Rails 2.3.8. I have several




你的当前访问异常,请进行认证后继续阅读剩余内容。

分享到: