switch to partial library for test compile

Test library compilation by making part of constructor a library