Skip to content

Commit

Permalink
issue #33 : added test files for later
Browse files Browse the repository at this point in the history
  • Loading branch information
zerwes committed Dec 5, 2023
1 parent 156c38a commit 70804b0
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 0 deletions.
22 changes: 22 additions & 0 deletions test/issue33-filter-test-expect.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version='1.0' encoding='UTF-8'?>
<opnsense>
<filter>
<rule>
<descr>icmp allow</descr>
<type>pass</type>
<ipprotocol>inet</ipprotocol>
<statetype>keep state</statetype>
<direction>any</direction>
<quick>1</quick>
<category>TEST</category>
<floating>yes</floating>
<protocol>icmp</protocol>
<source>
<any>1</any>
</source>
<destination>
<any>1</any>
</destination>
</rule>
</filter>
</opnsense>
22 changes: 22 additions & 0 deletions test/issue33-filter-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0"?>
<opnsense>
<filter>
<rule>
<descr>icmp allow</descr>
<type>pass</type>
<ipprotocol>inet</ipprotocol>
<statetype>keep state</statetype>
<direction>any</direction>
<quick>1</quick>
<category>TEST</category>
<floating>yes</floating>
<protocol>icmp</protocol>
<source>
<network>XYZ</network>
</source>
<destination>
<network>ABC</network>
</destination>
</rule>
</filter>
</opnsense>
30 changes: 30 additions & 0 deletions test/issue33-filter-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
---

#local_config_path: cfg/test1.xml

test_name: test consistent setting src/dest to network/address/any ...

opn_filter:
- descr: icmp allow
settings:
- key: type
value: pass
- key: ipprotocol
value: inet
- key: statetype
value: keep state
- key: direction
value: any
- key: quick
value: '1'
- key: category
value: TEST
- key: floating
value: 'yes'
- key: protocol
value: icmp
- key: source/any
value: '1'
- key: destination/any
value: '1'

0 comments on commit 70804b0

Please sign in to comment.