* Split the latest version check code into functions for unit testing * Add initial unit tests for latest version check