You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A majority of the unit tests depend on a database connections. This was a conscious decision, as we said that the DB is an integral part of simtools.
I think we learnt in the meanwhile that we can replace the DB connections in most cases using the unittest/pytest mocking mechanism. We should apply this wherever possible.
Given the large number of unittests, implementing this for all existing tests is a huge task.
Suggest to:
use mocking when implementing new tests
change existing tests whenever we touch the test code
An ideal solution would be to have no / very few DB connections in unit tests. Those which require a connection should get a pytest label.
The text was updated successfully, but these errors were encountered:
A majority of the unit tests depend on a database connections. This was a conscious decision, as we said that the DB is an integral part of simtools.
I think we learnt in the meanwhile that we can replace the DB connections in most cases using the unittest/pytest mocking mechanism. We should apply this wherever possible.
Given the large number of unittests, implementing this for all existing tests is a huge task.
Suggest to:
An ideal solution would be to have no / very few DB connections in unit tests. Those which require a connection should get a pytest label.
The text was updated successfully, but these errors were encountered: