Prime factors factory tests