Integer (final String className, final String testName) { int posProximity = testName.indexOf(className); int sizeProximity = testName.length() - className.length(); return posProximity + sizeProximity; }