Added QUnit for testing, wrote some tests

Tests WILL fail, due to not being completely written.