maratonusp / contestwatcher

A telegram bot for checking upcoming contests
MIT License
55 stars 16 forks source link

specific test environment for codeforces features #34

Open gabrielrussoc opened 6 years ago

gabrielrussoc commented 6 years ago

it sounds a good idea to have a simple way to test if the rating changes are working as they should.

victorsenam commented 6 years ago

This is not a specific test environment. It's just testing... Create a fixture for some sample data that should be received by the API call and then you can properly test everything.

gabrielrussoc commented 6 years ago

We have to refactor everything to test it properly. Right now I don't think there is a good way to automatically test it because of heavy coupling.

victorsenam commented 6 years ago

We can try behaviour/acceptance testing only. I believe it's a better idea to focus on refactoring so that easy testing becomes possible. We should change this issue so that it is about testing this feature, instead of suggesting creating new test environments.

gabrielrussoc commented 6 years ago

right now is not possible to test it without changing the code by hand

victorsenam commented 6 years ago

@gabrielrussoc You can stub what you need to change. Check out the testing done for alerta.