Lines Matching refs:a

6 Prophecy is a highly opinionated yet very powerful and flexible PHP object mocking
71 First of all, in Prophecy every word has a logical meaning, even the name of the library
77 those object prophecies can't create themselves - there should be a Prophet:
89 The result of the `prophesize()` method call is a new object of class `ObjectProphecy`. Yes,
113 The `$dummy` variable now holds a special dummy object. Dummy objects are objects that extend
118 a token object to satisfy a method typehint.
120 You need to understand one thing - a dummy is not a prophecy. Your object prophecy is still
122 should work with it. `$dummy` is a dummy - a simple php object that tries to fulfil your
133 but bear with me for a minute. Simply put, a stub is a dummy, which depending on the called
141 call returned us a new object instance of class `MethodProphecy`. Yep, that's a specific
149 As a matter of fact, the call that we made earlier (`willReturn('value')`) is a simple
160 - `ReturnPromise` or `->willReturn(1)` - returns a value from a method call
163 - `CallbackPromise` or `->will($callback)` - gives you a quick way to define your own custom logic
170 Prophecy enforces same method prophecies and, as a consequence, same promises and
212 optimal enough. We hardcoded `'everzet'` in our expectation. Isn't there a better
218 wildcards. As a matter of fact, `->setName('everzet')` looks like a simple call just
227 with your expectations. And yes, those classnames are damn big. That's why there's a
237 That's why Prophecy comes bundled with a bunch of other tokens:
239 - `IdenticalValueToken` or `Argument::is($value)` - checks that the argument is identical to a spec…
240 - `ExactValueToken` or `Argument::exact($value)` - checks that the argument matches a specific value
241 - `TypeToken` or `Argument::type($typeOrClass)` - checks that the argument matches a specific type …
244 a specific value
245 - `CallbackToken` or `Argument::that(callback)` - checks that the argument matches a custom callback
248 …or `Argument::containingString($value)` - checks that the argument contains a specific string value
306 arguments wildcarding works. Every argument token type has a different score level, which
324 (object being *dummy*). As a matter of fact, after you define your first promise
327 calling it on a stub.
343 Predictions are a delayed behavior check for your prophecies. You see, during the entire lifetime
347 `MethodProphecy::should(PredictionInterface $prediction)` method. As a matter of fact,
348 the `shouldBeCalled()` method we used earlier is just a shortcut to: