Creating a Unit test which tests partial routines
I was wondering if anyone has ever created a unit test which would run testing a mac routine (old fashion), via 1. Setup all the variables.
2. Run a unit test on routine from line x to line x +100…
I know it sounds a bit odd, since line numbers do change, and therefore - these unit tests may not be as stable.
Just curious if anyone ever wrote something like this. Obviously in some older code there may be a routines out there which have 1000’s of lines of code, and testing the entire thing is extremely difficult, but testing a small logically bound chunks - would be useful.
Not sure if anyone came across this and how was it implemented.
Thank you,
Alex