something like this ?

    boolean fileNamesAreSame = FilenameUtils.equalsNormalizedOnSystem("./src/test/resources/res/different_screen_sizes.xml",
        resources.getText(R.layout.different_screen_sizes, "value").toString());

    assertThat(fileNamesAreSame);