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

Write Testcases for the whole Codebase #235

Open
abhinavtripathy opened this issue Jun 11, 2020 · 4 comments
Open

Write Testcases for the whole Codebase #235

abhinavtripathy opened this issue Jun 11, 2020 · 4 comments
Assignees
Labels
Backend Team Enhancement New feature or request help wanted Extra attention is needed

Comments

@abhinavtripathy
Copy link
Member

Writing tests would improve our codebase as whole and we will lead to lesser bugs.

@abhinavtripathy abhinavtripathy added Enhancement New feature or request help wanted Extra attention is needed cleanup Backend Team and removed cleanup labels Jun 11, 2020
@abhinavtripathy abhinavtripathy self-assigned this Jun 17, 2020
@harsh183
Copy link

Sure, start with model unit testing.

@harsh183
Copy link

Probably open up a few more issues something more specific like 'Write test for X Model' or 'Improve Integrate Test for Hardware Loan'?

@harsh183
Copy link

Check out shoulda-matchers it will considerably help you with writing the simple test cases quick.

https://guides.railsgirls.com/testing-shoulda-matchers

https://github.com/thoughtbot/shoulda-matchers

Once you've written test cases you can integrate it into your CI very smoothly and refactor your code far more confidently.

@harsh183
Copy link

Since you asked for a few examples take a look at this gist. I do suggest setting up capybara for integration testing as well (and my gist has a few links to good tutorials)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Backend Team Enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants