-
Notifications
You must be signed in to change notification settings - Fork 10
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
Add unit tests #171
Comments
What are some examples of currently existing tests? |
we don't have much in the way of tests yet - just some *-test.js files that run in node that were used to help develop the code, not geared towards automation. critical areas would be any complex/confusing code - eg the jobboss shift handling, availability shift handling, adapter cache calculation code could start by instrumenting that code for tests. along the way help make code more functional and easier to understand. and for future code, i haven't had much luck sticking with TDD in other projects, but could try that going forward. @tukusejssirs what about you? |
IMO having tests for all units (at the very least functions and methods) would be very nice, however, it takes some time to create robust tests. We could even track the test coverage. While I was thinking about using TDD approach, however, I am more acustomed to be create the code first, then tests (after the code is more or less ready to merge, before merging), as the code change and while coding, I can create a list of test cases (based on the conditions in the code), which I can’t create out of the blue before the code is built. IMO, we should try to add tests whenever when add new features or update (enhance, possible fix some bugs) the code. Or we could wait until a particular app is moved to Nx, then start adding the tests. In either case, there is no need to add all the unit tests systematically right now, as we don’t have the manpower for that right now. |
@bburns TDD requires specifications up front. It won't work without spec or design model. |
Okay - it makes sense to start adding tests for new features after we move services into Nx, since it includes Jest. Could start with the Meter service, since we'll be adding code for OEE there. |
Yeah, I was about to ask you which app (service) would be (in your opinion) the easiest to move to Nx workspace first. I was thinking about one that does not depend on ther services (so that it could be easily tested without Docker). Moving the app itself is the easiest part, we need to adjust (a bit) global Nx config and probably the project-level config too. There are so many options … Do you think that |
I would be OK with |
No description provided.
The text was updated successfully, but these errors were encountered: