feat: add gateway setup wizard and fix test suite
New zt-gateway-setup script with subcommands for configuring this router as a ZeroTier exit gateway: bridge, routing (tables 100/101), DHCP, hotplug, and persistence. Exposes setup ubus method via backend with ACL and LuCI panel in overview. Also fixes two pre-existing test issues: - overview.spec.ts: active gateway radio is intentionally enabled (users need to re-trigger switch for the already-selected gateway) - drain.spec.ts: stubs drain status via page.route() since Docker has no real conntrack entries; fixed Playwright glob pattern bug where **/ubus* fails to match /ubus/?timestamp (regex needed)
This commit is contained in:
@@ -21,10 +21,10 @@ test('displays gateway table with correct rows', async ({ page }) => {
|
||||
await expect(activeRow).toHaveCount(1);
|
||||
});
|
||||
|
||||
test('active gateway radio is disabled', async ({ page }) => {
|
||||
const activeRow = page.locator('.zt-gateway-row', { hasText: 'active' });
|
||||
const radio = activeRow.locator('input[type=radio]');
|
||||
await expect(radio).toBeDisabled();
|
||||
test('active gateway radio is enabled', async ({ page }) => {
|
||||
const activeRow = page.locator('.zt-gateway-row', { hasText: 'active' });
|
||||
const radio = activeRow.locator('input[type=radio]');
|
||||
await expect(radio).toBeEnabled();
|
||||
});
|
||||
|
||||
test('non-active gateway radios are enabled', async ({ page }) => {
|
||||
|
||||
Reference in New Issue
Block a user