diff --git a/tests/Feature/AdminDashboardBillingWorkbenchBmpaProcessableButtonShouldHaveDataRoleAndQueryTest.php b/tests/Feature/AdminDashboardBillingWorkbenchBmpaProcessableButtonShouldHaveDataRoleAndQueryTest.php new file mode 100644 index 0000000..52f2c88 --- /dev/null +++ b/tests/Feature/AdminDashboardBillingWorkbenchBmpaProcessableButtonShouldHaveDataRoleAndQueryTest.php @@ -0,0 +1,36 @@ +seed(); + + $this->post('/admin/login', [ + 'email' => 'platform.admin@demo.local', + 'password' => 'Platform@123456', + ])->assertRedirect('/admin'); + } + + public function test_dashboard_billing_workbench_bmpa_processable_button_should_have_data_role_and_query(): void + { + $this->loginAsPlatformAdmin(); + + $res = $this->get('/admin'); + $res->assertOk(); + + $html = (string) $res->getContent(); + + $this->assertStringContainsString('data-role="dashboard-po-quicklink-bmpa-processable"', $html); + + // 口径:可BMPA处理入口应指向 bmpa_processable_only=1 集合(避免只靠“unpaid_pending”等内部别名导致语义漂移) + $this->assertStringContainsString('bmpa_processable_only=1', $html); + } +}