From d4410644a82dd242b5905babd6a6bc8125a7ada6 Mon Sep 17 00:00:00 2001 From: Dane Powell Date: Wed, 3 Nov 2021 11:16:33 -0700 Subject: [PATCH] Fix #332: Calling original method is unsupported --- README.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/README.md b/README.md index f0d2ff089..fbb58f69b 100644 --- a/README.md +++ b/README.md @@ -402,3 +402,10 @@ $em->flush()->shouldHaveBeenCalled(); ``` Such manipulation with doubles is called spying. And with Prophecy it just works. + + +## FAQ + +### Can I call the original methods on a prophesized class? + +Prophecy does not support calling the original methods on a phrophesized class. If you find yourself needing to mock some methods of a class while calling the original version of other methods, it's likely a sign that your class violates the [single-responsibility principle](https://en.wikipedia.org/wiki/Single-responsibility_principle) and should be refactored.