External library testing integration?

I am using an external library in a java project, but I am not sure how to integrate it with my code. For example: let's say I'm using a string encryption library to encrypt passwords.

Please enlighten.

thank

0


source to share


1 answer


You are probably thinking about integration testing, not unit testing. I usually don't unit test code that isn't mine. What I would like to do for integration testing is basically writing tests like my unit tests for my code, but not mocking an external library - i.e. Use it directly. You may need to do some customization to create the test environment, including any data that you want to use in the test in which it needs to be done. Integration tests can be less extensive than your unit tests, since you really only need to test paths that execute external functions, not necessarily all paths through your code.



+2


source







All Articles