Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not stub the Kaminari methods on AbstractSessionProxy #3

Open
leehambley opened this issue Aug 1, 2011 · 2 comments
Open

Does not stub the Kaminari methods on AbstractSessionProxy #3

leehambley opened this issue Aug 1, 2011 · 2 comments

Comments

@leehambley
Copy link
Contributor

When in test-mode, Sunspot provides a AbstractSessionProxy, the purpose being to effectively stub the interaction with Sunspot on non-search related tests to keep things fast.

We use this in the majority of our tests (as I'm sure, do many others) - would it be possible to also support this class, extending the other methods?

Implementation at : https://github.com/outoftime/sunspot/blob/master/sunspot/lib/sunspot/session_proxy/abstract_session_proxy.rb

I'd think a re-factoring of sunspot_with_kaminari to be a module, which is mixed-into the regular sunspot session, and can be mixed-into the sunspot session proxy, would be a good solution?

@richardiux
Copy link
Owner

Go for it! Give it a try.

Also I haven't found a way to test the integration with sunspot/kaminari. Do you have any ideas on how to do that?

@ylansegal
Copy link

Hey,

I was interested in that as well. I ended up just monkey patching to get my tests to pass, but it's hardly an elegant solution:

ylansegal@006e6c1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants