Add a test case, the main of the file is dirty. Don't panic it's the test stuff. It seems to work