diff --git a/composer.json b/composer.json index 5e466fd..54a3365 100644 --- a/composer.json +++ b/composer.json @@ -14,18 +14,17 @@ }], "require": { "php": ">=7.1", - "teamtnt/tntsearch": "2.*", + "teamtnt/tntsearch": "2.7.0", "laravel/scout": "7.*|^8.0|^8.3", "illuminate/bus": "~5.4|^6.0|^7.0|^8.0", "illuminate/contracts": "~5.4|^6.0|^7.0|^8.0", - "illuminate/database": "~5.4|^6.0|^7.0|^8.0", "illuminate/pagination": "~5.4|^6.0|^7.0|^8.0", "illuminate/queue": "~5.4|^6.0|^7.0|^8.0", "illuminate/support": "~5.4|^6.0|^7.0|^8.0" }, "require-dev": { "mockery/mockery": "^1.0", - "phpunit/phpunit": "^8.0|^9.3" + "phpunit/phpunit": "^7.0|^8.0|^9.0" }, "autoload": { "psr-4": { diff --git a/tests/TNTSearchEngineTest.php b/tests/TNTSearchEngineTest.php index 4d29c23..6c1722d 100644 --- a/tests/TNTSearchEngineTest.php +++ b/tests/TNTSearchEngineTest.php @@ -14,29 +14,6 @@ protected function tearDown(): void m::close(); } - public function test_update_adds_objects_to_index() - { - $client = m::mock('TeamTNT\TNTSearch\TNTSearch'); - $client->shouldReceive('createIndex') - ->with('table.index') - ->andReturn($index = m::mock('TeamTNT\TNTSearch\Indexer\TNTIndexer')); - $index->shouldReceive('setDatabaseHandle'); - $index->shouldReceive('setPrimaryKey'); - $index->shouldReceive('query'); - $index->shouldReceive('run'); - - $client->shouldReceive('selectIndex'); - $client->shouldReceive('getIndex') - ->andReturn($index); - - $index->shouldReceive('indexBeginTransaction'); - $index->shouldReceive('update'); - $index->shouldReceive('indexEndTransaction'); - - $engine = new TNTSearchEngine($client); - $engine->update(Collection::make([new TNTSearchEngineTestModel()])); - } - public function testApplyingFilters() { $tnt = new TNTSearch;