Separate production code from test code

Separate production code from test code