2525use PHPCR \Util \NodeHelper ;
2626use PHPCR \Util \PathHelper ;
2727use Symfony \Component \Filesystem \Filesystem ;
28- use Webmozart \Assert \Assert ;
2928
3029/**
3130 * Features context.
@@ -200,7 +199,7 @@ public function iShouldSeeATableContainingTheFollowingRows(TableNode $table)
200199 }
201200 }
202201
203- Assert:: greaterThanEq (count ($ expectedRows ), $ foundRows , $ this ->getOutput ());
202+ \PHPUnit_Framework_Assert:: assertGreaterThanOrEqual (count ($ expectedRows ), $ foundRows , $ this ->getOutput ());
204203 }
205204
206205 /**
@@ -209,7 +208,7 @@ public function iShouldSeeATableContainingTheFollowingRows(TableNode $table)
209208 public function iShouldSeeTheFollowing (PyStringNode $ string )
210209 {
211210 $ output = $ this ->getOutput ();
212- Assert:: contains ($ string ->getRaw (), $ output );
211+ \PHPUnit_Framework_Assert:: assertContains ($ string ->getRaw (), $ output );
213212 }
214213
215214 /**
@@ -218,7 +217,7 @@ public function iShouldSeeTheFollowing(PyStringNode $string)
218217 public function iShouldNotSeeTheFollowing (PyStringNode $ string )
219218 {
220219 $ output = $ this ->getOutput ();
221- Assert:: notContains ($ string ->getRaw (), $ output );
220+ \PHPUnit_Framework_Assert:: assertNotContains ($ string ->getRaw (), $ output );
222221 }
223222
224223 /**
@@ -249,7 +248,7 @@ public function theCommandShouldNotFail()
249248 throw new \Exception ('Command failed: ( ' .$ exitCode .') ' .$ this ->getOutput ());
250249 }
251250
252- Assert:: eq (0 , $ exitCode , 'Command exited with code: ' .$ exitCode );
251+ \PHPUnit_Framework_Assert:: assertEquals (0 , $ exitCode , 'Command exited with code: ' .$ exitCode );
253252 }
254253
255254 /**
@@ -259,7 +258,7 @@ public function theCommandShouldFail()
259258 {
260259 $ exitCode = $ this ->applicationTester ->getLastExitCode ();
261260
262- Assert:: notEq (0 , $ exitCode , 'Command exited with code ' .$ exitCode );
261+ \PHPUnit_Framework_Assert:: assertNotEquals (0 , $ exitCode , 'Command exited with code ' .$ exitCode );
263262 }
264263
265264 /**
@@ -270,15 +269,15 @@ public function theCommandShouldFailWithMessage($arg1)
270269 $ exitCode = $ this ->applicationTester ->getLastExitCode ();
271270 $ output = $ this ->getOutput ();
272271
273- Assert:: eq ($ arg1 , $ output );
272+ \PHPUnit_Framework_Assert:: assertEquals ($ arg1 , $ output );
274273 }
275274
276275 /**
277276 * @Given /^the file "([^"]*)" should exist$/
278277 */
279278 public function theFileShouldExist ($ arg1 )
280279 {
281- Assert:: true (file_exists ($ this ->getWorkingFilePath ($ arg1 )));
280+ \PHPUnit_Framework_Assert:: assertTrue (file_exists ($ this ->getWorkingFilePath ($ arg1 )));
282281 }
283282
284283 /**
@@ -305,7 +304,7 @@ public function theFileExists($arg1)
305304 public function theOutputShouldContain (PyStringNode $ string )
306305 {
307306 foreach ($ string ->getStrings () as $ line ) {
308- Assert:: contains ($ line , $ this ->getOutput ());
307+ \PHPUnit_Framework_Assert:: assertContains ($ line , $ this ->getOutput ());
309308 }
310309 }
311310
@@ -316,7 +315,7 @@ public function theNodeShouldNotExist($arg1)
316315 {
317316 $ session = $ this ->getSession ();
318317 $ node = $ session ->getNode ($ arg1 );
319- Assert:: null ($ node );
318+ \PHPUnit_Framework_Assert:: assertNull ($ node );
320319 }
321320
322321 /**
@@ -327,7 +326,7 @@ public function theXpathCountIsInFile($arg1, $arg2, $arg3)
327326 $ xpath = $ this ->getXPathForFile ($ arg3 );
328327 $ res = $ xpath ->query ($ arg1 );
329328
330- Assert:: eq ($ arg2 , $ res ->length );
329+ \PHPUnit_Framework_Assert:: assertEquals ($ arg2 , $ res ->length );
331330 }
332331
333332 /**
@@ -364,7 +363,7 @@ public function iShouldNotBeLoggedIntoTheSession()
364363 {
365364 $ this ->executeCommand ('session:info ' );
366365 $ output = $ this ->getOutput ();
367- Assert:: regex ('/live .*no/ ' , $ output );
366+ \PHPUnit_Framework_Assert:: assertRegExp ('/live .*no/ ' , $ output );
368367 }
369368
370369 /**
@@ -428,7 +427,7 @@ public function thereShouldExistANodeAtBefore($arg1, $arg2)
428427 throw new \Exception ('Could not find child node ' .$ arg1 );
429428 }
430429
431- Assert:: eq ($ arg2 , $ afterNode ->getPath ());
430+ \PHPUnit_Framework_Assert:: assertEquals ($ arg2 , $ afterNode ->getPath ());
432431 }
433432
434433 /**
@@ -531,7 +530,7 @@ public function thenIShouldBeLoggedInAs($arg1)
531530 $ session = $ this ->getSession ();
532531 $ userId = $ session ->getUserID ();
533532
534- Assert:: eq ($ userId , $ arg1 );
533+ \PHPUnit_Framework_Assert:: assertEquals ($ userId , $ arg1 );
535534 }
536535
537536 /**
@@ -691,7 +690,7 @@ public function theCurrentNodeShouldBe($arg1)
691690 {
692691 $ this ->executeCommand ('shell:path:show ' );
693692 $ cnp = $ this ->applicationTester ->getLastLine ();
694- Assert:: eq ($ arg1 , $ cnp , 'Current path is ' .$ arg1 );
693+ \PHPUnit_Framework_Assert:: assertEquals ($ arg1 , $ cnp , 'Current path is ' .$ arg1 );
695694 }
696695
697696 /**
@@ -729,7 +728,7 @@ public function thePrimaryTypeOfShouldBe($arg1, $arg2)
729728 $ session = $ this ->getSession ();
730729 $ node = $ session ->getNode ($ arg1 );
731730 $ primaryTypeName = $ node ->getPrimaryNodeType ()->getName ();
732- Assert:: eq ($ arg2 , $ primaryTypeName , 'Node type of ' .$ arg1 .' is ' .$ arg2 );
731+ \PHPUnit_Framework_Assert:: assertEquals ($ arg2 , $ primaryTypeName , 'Node type of ' .$ arg1 .' is ' .$ arg2 );
733732 }
734733
735734 /**
@@ -746,7 +745,7 @@ public function theNodeAtShouldHaveThePropertyWithValue($arg1, $arg2, $arg3)
746745 $ propertyValue = $ propertyValue ->getIdentifier ();
747746 }
748747
749- Assert:: eq ($ arg3 , $ propertyValue );
748+ \PHPUnit_Framework_Assert:: assertEquals ($ arg3 , $ propertyValue );
750749 }
751750
752751 /**
@@ -762,7 +761,7 @@ public function theNodeAtShouldHaveThePropertyWithValueAtIndex($arg1, $arg2, $ar
762761 }
763762
764763 $ propertyType = $ property ->getValue ();
765- Assert:: eq ($ arg3 , $ propertyType [$ index ]);
764+ \PHPUnit_Framework_Assert:: assertEquals ($ arg3 , $ propertyType [$ index ]);
766765 }
767766
768767 /**
@@ -778,7 +777,7 @@ public function thePropertyShouldHaveType($arg1, $arg2)
778777 ));
779778 }
780779
781- Assert:: eq ($ arg2 , PropertyType::nameFromValue ($ property ->getType ()));
780+ \PHPUnit_Framework_Assert:: assertEquals ($ arg2 , PropertyType::nameFromValue ($ property ->getType ()));
782781 }
783782
784783 /**
@@ -794,8 +793,8 @@ public function thePropertyShouldHaveTypeAndValue($arg1, $arg2, $arg3)
794793 ));
795794 }
796795
797- Assert:: eq ($ arg2 , PropertyType::nameFromValue ($ property ->getType ()));
798- Assert:: eq ($ arg3 , $ property ->getValue ());
796+ \PHPUnit_Framework_Assert:: assertEquals ($ arg2 , PropertyType::nameFromValue ($ property ->getType ()));
797+ \PHPUnit_Framework_Assert:: assertEquals ($ arg3 , $ property ->getValue ());
799798 }
800799
801800 /**
@@ -865,7 +864,7 @@ public function theNodeShouldBeLocked($arg1)
865864 $ lockManager = $ workspace ->getLockManager ();
866865 $ isLocked = $ lockManager ->isLocked ($ arg1 );
867866
868- Assert:: true ($ isLocked );
867+ \PHPUnit_Framework_Assert:: assertTrue ($ isLocked );
869868 }
870869
871870 /**
@@ -878,7 +877,7 @@ public function theNodeShouldNotBeLocked($arg1)
878877 $ lockManager = $ workspace ->getLockManager ();
879878 $ isLocked = $ lockManager ->isLocked ($ arg1 );
880879
881- Assert:: false ($ isLocked );
880+ \PHPUnit_Framework_Assert:: assertFalse ($ isLocked );
882881 }
883882
884883 /**
0 commit comments