New functionality tested

Code needs cleanup