Edited a lot of code, created six test cases, they all passed.
Fixed merge conflicts.