diff --git a/src/main/resources/com/google/api/codegen/php/test.snip b/src/main/resources/com/google/api/codegen/php/test.snip index 805b24d587..5f5de62d37 100644 --- a/src/main/resources/com/google/api/codegen/php/test.snip +++ b/src/main/resources/com/google/api/codegen/php/test.snip @@ -32,9 +32,7 @@ */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** diff --git a/src/test/java/com/google/api/codegen/gapic/testdata/php/php_library.baseline b/src/test/java/com/google/api/codegen/gapic/testdata/php/php_library.baseline index 28c7cfa318..0875d7ec78 100644 --- a/src/test/java/com/google/api/codegen/gapic/testdata/php/php_library.baseline +++ b/src/test/java/com/google/api/codegen/gapic/testdata/php/php_library.baseline @@ -5929,9 +5929,7 @@ class LibraryServiceClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** @@ -8868,9 +8866,7 @@ class MyProtoClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** diff --git a/src/test/java/com/google/api/codegen/gapic/testdata/php/php_longrunning.baseline b/src/test/java/com/google/api/codegen/gapic/testdata/php/php_longrunning.baseline index ee68b02cf2..b2d9c18517 100644 --- a/src/test/java/com/google/api/codegen/gapic/testdata/php/php_longrunning.baseline +++ b/src/test/java/com/google/api/codegen/gapic/testdata/php/php_longrunning.baseline @@ -755,9 +755,7 @@ class OperationsClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** diff --git a/src/test/java/com/google/api/codegen/gapic/testdata/php/php_no_path_templates.baseline b/src/test/java/com/google/api/codegen/gapic/testdata/php/php_no_path_templates.baseline index ae0e953913..c8e107b951 100644 --- a/src/test/java/com/google/api/codegen/gapic/testdata/php/php_no_path_templates.baseline +++ b/src/test/java/com/google/api/codegen/gapic/testdata/php/php_no_path_templates.baseline @@ -396,9 +396,7 @@ class NoTemplatesApiServiceClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** diff --git a/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library.baseline b/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library.baseline index 8a1e687e4a..a7b52f7918 100644 --- a/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library.baseline +++ b/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library.baseline @@ -6958,9 +6958,7 @@ class LibraryServiceClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** @@ -10254,9 +10252,7 @@ class MyProtoClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** diff --git a/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library_with_grpc_service_config.baseline b/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library_with_grpc_service_config.baseline index daff2c49b8..5e304559e7 100644 --- a/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library_with_grpc_service_config.baseline +++ b/src/test/java/com/google/api/codegen/protoannotations/testdata/php_library_with_grpc_service_config.baseline @@ -6983,9 +6983,7 @@ class LibraryServiceClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /** @@ -10279,9 +10277,7 @@ class MyProtoClientTest extends GeneratedTest */ private function createCredentials() { - return $this->getMockBuilder(CredentialsWrapper::class) - ->disableOriginalConstructor() - ->getMock(); + return $this->prophesize(CredentialsWrapper::class)->reveal(); } /**