@Test
    public void testOrderness() {
        assertMetrics("orderness:1",  "a","a");
        assertMetrics("orderness:1",  "a","x");
        assertMetrics("orderness:0",  "a a a","a"); // Oh well...
        assertMetrics("orderness:1",  "a","a a a");
        assertMetrics("orderness:0",  "a b","b a");
        assertMetrics("orderness:0.5","a b c","b a c");
        assertMetrics("orderness:0.5","a b c d","c b d x x x x x x x x x x x x x x x x x x x x x a");
        assertMetrics("orderness:1",  "a b","b x x x x x x x x x x x x x x x x x x x x x a");
    }
Tests of calculation of all the string match metrics.
Add true as the fourth parameter to assertMetrics to see a trace of what the test is doing.

@author bratseth
searchlib/src/test/java/com/yahoo/searchlib/ranking/features/fieldmatch/test/FieldMatchMetricsTestCase.java