From d2085b7d4f2452139ab0949820d6b463deb1081f Mon Sep 17 00:00:00 2001 From: zeke Date: Fri, 8 Dec 2017 16:49:06 -0800 Subject: [PATCH 1/3] notes on running tests --- README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/README.md b/README.md index 9029d20..41fcffc 100644 --- a/README.md +++ b/README.md @@ -273,3 +273,11 @@ $manager->extend('custom_connection_name', function ($config) { // get an instance of your custom connection $pubsub = $manager->connection('custom_connection_name'); ``` + +## Contributing + +### Running Tests + +Run `composer install` to ensure local installation of dependencies. + +Run `make tests` to run test suite. \ No newline at end of file From 5d8d82282c846dae2efcafdbfa02dbb46e1fba44 Mon Sep 17 00:00:00 2001 From: zeke Date: Fri, 8 Dec 2017 16:56:07 -0800 Subject: [PATCH 2/3] kafka test run fixes --- tests/PubSubConnectionFactoryTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/PubSubConnectionFactoryTest.php b/tests/PubSubConnectionFactoryTest.php index e2dcebe..843a32f 100644 --- a/tests/PubSubConnectionFactoryTest.php +++ b/tests/PubSubConnectionFactoryTest.php @@ -126,14 +126,14 @@ public function testMakeKafkaAdapter() ->with($topicConf) ->once(); - $container->shouldReceive('make') + $container->shouldReceive('makeWith') ->with('pubsub.kafka.conf') ->once() ->andReturn($conf); $consumer = Mockery::mock(\RdKafka\KafkaConsumer::class); - $container->shouldReceive('make') + $container->shouldReceive('makeWith') ->withArgs([ 'pubsub.kafka.consumer', ['conf' => $conf], From 9443db0c8e92e51600ec837ca42ba440c7a8a766 Mon Sep 17 00:00:00 2001 From: zeke Date: Fri, 8 Dec 2017 16:57:39 -0800 Subject: [PATCH 3/3] note on testing the kafka bridge --- README.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 41fcffc..f3d7cb5 100644 --- a/README.md +++ b/README.md @@ -280,4 +280,11 @@ $pubsub = $manager->connection('custom_connection_name'); Run `composer install` to ensure local installation of dependencies. -Run `make tests` to run test suite. \ No newline at end of file +Run `make tests` to run test suite. + +If you need to run Kafka tests, install the Kafka bridge (note you still need to install the C library and PHP extension +separately): + +```bash +composer require superbalist/php-pubsub-kafka +``` \ No newline at end of file