aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/front
diff options
context:
space:
mode:
Diffstat (limited to 'tests/front')
-rw-r--r--tests/front/controller/admin/ShaareManageControllerTest/DeleteBookmarkTest.php6
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/front/controller/admin/ShaareManageControllerTest/DeleteBookmarkTest.php b/tests/front/controller/admin/ShaareManageControllerTest/DeleteBookmarkTest.php
index 770a16d7..a276d988 100644
--- a/tests/front/controller/admin/ShaareManageControllerTest/DeleteBookmarkTest.php
+++ b/tests/front/controller/admin/ShaareManageControllerTest/DeleteBookmarkTest.php
@@ -38,6 +38,8 @@ class DeleteBookmarkTest extends TestCase
38 { 38 {
39 $parameters = ['id' => '123']; 39 $parameters = ['id' => '123'];
40 40
41 $this->container->environment['HTTP_REFERER'] = 'http://shaarli/subfolder/shaare/abcdef';
42
41 $request = $this->createMock(Request::class); 43 $request = $this->createMock(Request::class);
42 $request 44 $request
43 ->method('getParam') 45 ->method('getParam')
@@ -90,6 +92,8 @@ class DeleteBookmarkTest extends TestCase
90 { 92 {
91 $parameters = ['id' => '123 456 789']; 93 $parameters = ['id' => '123 456 789'];
92 94
95 $this->container->environment['HTTP_REFERER'] = 'http://shaarli/subfolder/?searchtags=abcdef';
96
93 $request = $this->createMock(Request::class); 97 $request = $this->createMock(Request::class);
94 $request 98 $request
95 ->method('getParam') 99 ->method('getParam')
@@ -152,7 +156,7 @@ class DeleteBookmarkTest extends TestCase
152 $result = $this->controller->deleteBookmark($request, $response); 156 $result = $this->controller->deleteBookmark($request, $response);
153 157
154 static::assertSame(302, $result->getStatusCode()); 158 static::assertSame(302, $result->getStatusCode());
155 static::assertSame(['/subfolder/'], $result->getHeader('location')); 159 static::assertSame(['/subfolder/?searchtags=abcdef'], $result->getHeader('location'));
156 } 160 }
157 161
158 /** 162 /**