Put some tests around this stuff

Put some tests around this stuff