Ejemplo n.º 1
0
 public function testConfigureWarning()
 {
     $warning_lines = array('CMake Warning (dev) at some/file/path:1234 (MESSAGE):', 'WARNING: blah blah blah');
     $non_warning_lines = array('warning: blah blah blah', 'WARNING : blah blah blah', 'WARNING some other text: blah blah blah', 'This warning is for project developers. Use -Wno-dev to suppress it.', '<<< Configuring library with warnings >>>', 'library warnings................. : yes');
     foreach ($warning_lines as $line) {
         if (!BuildConfigure::IsConfigureWarning($line)) {
             $this->fail("This was not considered a configure warning when it should be: {$line}");
         }
     }
     foreach ($non_warning_lines as $line) {
         if (BuildConfigure::IsConfigureWarning($line)) {
             $this->fail("This was considered a configure warning when it should not be: {$line}");
         }
     }
 }