Hacker News new | ask | show | jobs
by thinkingemote 2171 days ago
Look at the library's tests. It's quicker and better for learning functionality than "just read the source code".

If it's proprietary and closed and obfuscated then you need to familiarise yourself with reverse engineering toolsets.

3 comments

The corollary to this is, "If there aren't tests, start by writing some unit tests on your own that exercise the library's functionality."
maybe its just me and my avoidance of unit testing but often when i tried this it appeared overly complex at setting things up for testing and the code you need is buried in between some dozens tests and their setup. I think its a good idea to look at them but more often then not i did not want to get through this and just tried to understand the code flow by reading the source.
Seconding this! Tests are a wonderful way to quickly discovering the properties of the codebase that the authors considered important.