Skip to content

Commit

Permalink
test: disable batch operations on one-to-one relation resources
Browse files Browse the repository at this point in the history
  • Loading branch information
alexzarbn committed Jan 7, 2023
1 parent 0652519 commit e5f7a3d
Showing 1 changed file with 0 additions and 27 deletions.
27 changes: 0 additions & 27 deletions tests/Unit/OrionTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -106,10 +106,6 @@ function () {
$this->assertRouteRegistered('api.projects.meta.update', ['PUT', 'PATCH'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@update');
$this->assertRouteRegistered('api.projects.meta.destroy', ['DELETE'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@destroy');

$this->assertRouteRegistered('api.projects.meta.batchStore', ['POST'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchStore');
$this->assertRouteRegistered('api.projects.meta.batchUpdate', ['PATCH'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchUpdate');
$this->assertRouteRegistered('api.projects.meta.batchDestroy', ['DELETE'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchDestroy');

$this->assertRouteNotRegistered('api.projects.meta.index');
$this->assertRouteNotRegistered('api.projects.meta.search');
$this->assertRouteNotRegistered('api.projects.meta.restore');
Expand All @@ -132,11 +128,6 @@ function () {
$this->assertRouteRegistered('api.projects.meta.destroy', ['DELETE'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@destroy');
$this->assertRouteRegistered('api.projects.meta.restore', ['POST'], 'api/projects/{project}/meta/{metum?}/restore', DummyController::class.'@restore');

$this->assertRouteRegistered('api.projects.meta.batchStore', ['POST'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchStore');
$this->assertRouteRegistered('api.projects.meta.batchUpdate', ['PATCH'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchUpdate');
$this->assertRouteRegistered('api.projects.meta.batchDestroy', ['DELETE'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchDestroy');
$this->assertRouteRegistered('api.projects.meta.batchRestore', ['POST'], 'api/projects/{project}/meta/batch/restore', DummyController::class.'@batchRestore');

$this->assertRouteNotRegistered('api.projects.meta.index');
$this->assertRouteNotRegistered('api.projects.meta.search');
}
Expand Down Expand Up @@ -322,10 +313,6 @@ function () {
$this->assertRouteRegistered('api.projects.meta.update', ['PUT', 'PATCH'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@update');
$this->assertRouteRegistered('api.projects.meta.destroy', ['DELETE'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@destroy');

$this->assertRouteRegistered('api.projects.meta.batchStore', ['POST'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchStore');
$this->assertRouteRegistered('api.projects.meta.batchUpdate', ['PATCH'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchUpdate');
$this->assertRouteRegistered('api.projects.meta.batchDestroy', ['DELETE'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchDestroy');

$this->assertRouteNotRegistered('api.projects.meta.index');
$this->assertRouteNotRegistered('api.projects.meta.search');
$this->assertRouteNotRegistered('api.projects.meta.restore');
Expand All @@ -348,11 +335,6 @@ function () {
$this->assertRouteRegistered('api.projects.meta.destroy', ['DELETE'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@destroy');
$this->assertRouteRegistered('api.projects.meta.restore', ['POST'], 'api/projects/{project}/meta/{metum?}/restore', DummyController::class.'@restore');

$this->assertRouteRegistered('api.projects.meta.batchStore', ['POST'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchStore');
$this->assertRouteRegistered('api.projects.meta.batchUpdate', ['PATCH'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchUpdate');
$this->assertRouteRegistered('api.projects.meta.batchDestroy', ['DELETE'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchDestroy');
$this->assertRouteRegistered('api.projects.meta.batchRestore', ['POST'], 'api/projects/{project}/meta/batch/restore', DummyController::class.'@batchRestore');

$this->assertRouteNotRegistered('api.projects.meta.index');
$this->assertRouteNotRegistered('api.projects.meta.search');
}
Expand Down Expand Up @@ -427,10 +409,6 @@ function () {
$this->assertRouteRegistered('api.projects.meta.update', ['PUT', 'PATCH'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@update');
$this->assertRouteRegistered('api.projects.meta.destroy', ['DELETE'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@destroy');

$this->assertRouteRegistered('api.projects.meta.batchStore', ['POST'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchStore');
$this->assertRouteRegistered('api.projects.meta.batchUpdate', ['PATCH'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchUpdate');
$this->assertRouteRegistered('api.projects.meta.batchDestroy', ['DELETE'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchDestroy');

$this->assertRouteNotRegistered('api.projects.meta.index');
$this->assertRouteNotRegistered('api.projects.meta.search');
$this->assertRouteNotRegistered('api.projects.meta.restore');
Expand All @@ -453,11 +431,6 @@ function () {
$this->assertRouteRegistered('api.projects.meta.destroy', ['DELETE'], 'api/projects/{project}/meta/{metum?}', DummyController::class.'@destroy');
$this->assertRouteRegistered('api.projects.meta.restore', ['POST'], 'api/projects/{project}/meta/{metum?}/restore', DummyController::class.'@restore');

$this->assertRouteRegistered('api.projects.meta.batchStore', ['POST'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchStore');
$this->assertRouteRegistered('api.projects.meta.batchUpdate', ['PATCH'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchUpdate');
$this->assertRouteRegistered('api.projects.meta.batchDestroy', ['DELETE'], 'api/projects/{project}/meta/batch', DummyController::class.'@batchDestroy');
$this->assertRouteRegistered('api.projects.meta.batchRestore', ['POST'], 'api/projects/{project}/meta/batch/restore', DummyController::class.'@batchRestore');

$this->assertRouteNotRegistered('api.projects.meta.index');
$this->assertRouteNotRegistered('api.projects.meta.search');
}
Expand Down

0 comments on commit e5f7a3d

Please sign in to comment.