it('throws exception if any value is included', function () { shouldThrowException(function () { $expect = new Expectation(array('test', 'spec')); $expect->notToContain('bdd', 'spec'); }); }); it('returns if the string does not include any substring', function () { shouldReturn(function () { $expect = new Expectation('testing'); $expect->notToContain('TEST', 'ING'); }); }); it('throws exception if it includes a substring', function () { shouldThrowException(function () { $expect = new Expectation('testing'); $expect->notToContain('tests', 'test'); }); }); }); }); context('toContainAnyOf', function () { it('returns if the array contains one of the values', function () { shouldReturn(function () { $expect = new Expectation(array('test', 'spec')); $expect->toContainAnyOf('bdd', 'spec'); }); }); it('throws exception if none of the values are included', function () { shouldThrowException(function () { $expect = new Expectation(array('test', 'spec')); $expect->toContainAnyOf('tdd', 'bdd');