예제 #1
0
             $expect = new Expectation(null);
             $expect->notToBeNull();
         });
     });
 });
 context('toBeTrue', function () {
     it('returns if the value is true', function () {
         shouldReturn(function () {
             $expect = new Expectation(true);
             $expect->toBeTrue();
         });
     });
     it('throws exception if not true', function () {
         shouldThrowException(function () {
             $expect = new Expectation(1);
             $expect->toBeTrue();
         });
     });
 });
 context('notToBeTrue', function () {
     it('returns if the value is not true', function () {
         shouldReturn(function () {
             $expect = new Expectation(1);
             $expect->notToBeTrue();
         });
     });
     it('throws exception if true', function () {
         shouldThrowException(function () {
             $expect = new Expectation(true);
             $expect->notToBeTrue();
         });