In an out of tree build, the filenames from the pre-processor point of view are different, so didn't match the sample string. It's necessary to build the test string using the pre-processor's idea of the file name to get it to match consistently.