assertStringNotEqualsFile() public static method

Asserts that the contents of a string is not equal to the contents of a file.
public static assertStringNotEqualsFile ( string $expectedFile, string $actualString, string $message = '', boolean $canonicalize = false, boolean $ignoreCase = false )
$expectedFile string
$actualString string
$message string
$canonicalize boolean
$ignoreCase boolean
Example #1
0
/**
 * Asserts that the contents of a string is not equal
 * to the contents of a file.
 *
 * @param  string  $expectedFile
 * @param  string  $actualString
 * @param  string  $message
 * @param  boolean $canonicalize
 * @param  boolean $ignoreCase
 * @since  Method available since Release 3.3.0
 */
function assertStringNotEqualsFile($expectedFile, $actualString, $message = '', $canonicalize = FALSE, $ignoreCase = FALSE)
{
    return PHPUnit_Framework_Assert::assertStringNotEqualsFile($expectedFile, $actualString, $message, $canonicalize, $ignoreCase);
}
Example #2
0
 public function isNotEqualToFile($file)
 {
     Assert::assertStringNotEqualsFile($file, $this->actual, $this->description);
     return $this;
 }
Example #3
0
 /**
  * Expect that the contents of one file or a string is not equal to the contents of another file.
  *
  * @param string $expected
  * @param string $message
  * @param bool $canonicalize
  * @param bool $ignoreCase
  *
  * @return Expect
  */
 public function notToEqualFile($expected, $message = '', $canonicalize = false, $ignoreCase = false)
 {
     if (file_exists($this->value)) {
         // file
         Assert::assertFileNotEquals($expected, $this->value, $message, $canonicalize, $ignoreCase);
     } else {
         // string
         Assert::assertStringNotEqualsFile($expected, $this->value, $message, $canonicalize, $ignoreCase);
     }
     return $this;
 }
Example #4
0
 public function notEqualsFile($file)
 {
     a::assertStringNotEqualsFile($file, $this->actual, $this->description);
 }
Example #5
0
 /**
  * Asserts that the contents of a string is not equal
  * to the contents of a vfs file.
  *
  * @param $expectedFile
  * @param $actualString
  * @param string $message
  * @param bool|false $canonicalize
  * @param bool|false $ignoreCase
  */
 public function assertStringNotEqualsVfsFile($expectedFile, $actualString, $message = '', $canonicalize = false, $ignoreCase = false)
 {
     PHPUnit::assertStringNotEqualsFile($this->getPath($expectedFile), $actualString, $message, $canonicalize, $ignoreCase);
 }