I want to write some high level tests for my job filters. E.g. I want to ensure my filter does the right thing if a job fails. I was thinking I could use a dummy job that throws an exception and run this job in a test.
To do this I would like to mock out the persistence, but keep as much of the other code as possible.
From what I can see, I would need to use the Worker or JobPerformanceProcess classes. However, these are both internal.
I can see I can write a unit test that tests individual methods in my filter, but that isn’t the level of test I want.
Any ideas on how I can achieve this?