-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Dedicated fixtures in tests #1783
Comments
@hiddeco @2opremio I'd be willing to get a PR/discussion going on this and get feedback if you like (or agree that the current approach is good enough 😄) So from my understanding the challenges are:
Is there anything else I should take into account? |
I think it would also be good to have varied fixtures and incorporate fixtures employing |
By varied fixtures do you mean the ability to build different test data according to the needs of each test? Like fluent test data builders? |
Yes. |
I've opened a (WIP) PR to track this. Let me know if I'm going down the right path 🙂 |
I have moved the (non-encrypted) test fixtures to
Although they don't need to be shared, I can understand the convenience of having a single set of files. Do you think there's value in splitting them? I would also like some input before continuing with the test data builders as it can be subjective. I would use them for building complicated in-memory objects but in this case the simplicity of having the plain yaml there in each test may be preferred. If so, which tests would benefit more from using test data builders in your opinion? |
The PR that goes with this report has been closed by the contributor. I am closing this issue, as it appears to be outside the scope of maintenance mode in Flux v1. Thanks! |
From #1394 (comment)
The fixtures in
cluster/kubernetes/testfiles
are reused throughout the code base. We should write dedicated fixtures for each package that 'borrows' these so they become self-contained.The text was updated successfully, but these errors were encountered: