Skip to content
This repository was archived by the owner on Aug 15, 2026. It is now read-only.

Add bash import test fixture scripts - #3

Merged
studiowebux merged 1 commit into
mainfrom
feat/test-fixtures
Feb 28, 2026
Merged

studiowebux merged 1 commit into
mainfrom
feat/test-fixtures

Conversation

@studiowebux

Copy link
Copy Markdown
Owner

Summary

  • examples/import-basic.sh — comprehensive coverage: services, ports, protocols, sources, interfaces, target, forward, masquerade, forward-ports, source-ports, ICMP blocks, rich rules, direct chains/rules/passthroughs
  • examples/import-edge-cases.sh — shell variables (expect errors), zone-less commands (expect default to public), query/state/reload commands (expect skipped), non-firewall-cmd lines (expect skipped)
  • examples/import-webserver.sh — real-world multi-zone scenario: public (web + proxy), internal (database), trusted (management/SSH), Docker isolation via direct rules

Test plan

  • Open app, click Paste Commands, paste contents of each .sh file
  • import-basic.sh: all commands parsed, no errors
  • import-edge-cases.sh: 6 parsed into public zone, 3 errors (shell vars), rest skipped
  • import-webserver.sh: 3 zones + direct rules parsed, no errors

🤖 Generated with Claude Code

Three example scripts for testing the Paste Commands feature:
- import-basic.sh: comprehensive coverage of all zone/direct features
- import-edge-cases.sh: shell variables, zone-less commands, query
  commands, reload variants, non-firewall-cmd lines
- import-webserver.sh: real-world multi-zone web server scenario

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@studiowebux
studiowebux merged commit d3b047c into main Feb 28, 2026
1 check passed
@studiowebux
studiowebux deleted the feat/test-fixtures branch February 28, 2026 04:15
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant