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

Code Smells in BookingShould Duplicate Code #61

Open
Mykyta-Panchenko opened this issue Feb 7, 2025 · 0 comments · May be fixed by #62
Open

Code Smells in BookingShould Duplicate Code #61

Mykyta-Panchenko opened this issue Feb 7, 2025 · 0 comments · May be fixed by #62

Comments

@Mykyta-Panchenko
Copy link

Problem:
Each test method repeats the same object instantiation for the Booking class. This makes it harder to maintain and increases the chances of errors when updating the test data.

Fix:
Extract the Booking creation logic into a separate private method.
Allow passing custom dates to make tests more readable.

@Mykyta-Panchenko Mykyta-Panchenko linked a pull request Feb 7, 2025 that will close this issue
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

Successfully merging a pull request may close this issue.

1 participant