Skip to content
This repository has been archived by the owner on Jul 19, 2024. It is now read-only.

notes on running tests, test fixes #14

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -273,3 +273,18 @@ $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.

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
```
4 changes: 2 additions & 2 deletions tests/PubSubConnectionFactoryTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -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],
Expand Down