Added matchesString variant where you can specify the window to return.
Fixed tests.
Added test for window variant of comparison method.