refactor(site-subscriptions): dedupe show page back actions
This commit is contained in:
@@ -66,5 +66,13 @@ class AdminSiteSubscriptionShowIndexLinkKeepsContextTest extends TestCase
|
||||
|
||||
$res->assertSee('返回订阅列表(保留上下文)');
|
||||
$res->assertSee($expectedIndexUrl, false);
|
||||
|
||||
// 当传入有效 back 时,应优先显示“返回上一页”并隐藏该兜底按钮(避免重复入口噪音)
|
||||
$res2 = $this->get('/admin/site-subscriptions/' . $sub->id . '?' . Arr::query([
|
||||
'back' => '/admin',
|
||||
]));
|
||||
$res2->assertOk();
|
||||
$res2->assertSee('返回上一页(保留上下文)');
|
||||
$res2->assertDontSee('返回订阅列表(保留上下文)');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user