Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Fukász Rómeó Ervin
/
cloud
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
bad4afd4
authored
Nov 17, 2014
by
Bach Dániel
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
firewall: fix tests
parent
014cda7a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
8 deletions
+0
-8
circle/firewall/models.py
+0
-3
circle/firewall/tests/test_firewall.py
+0
-5
No files found.
circle/firewall/models.py
View file @
bad4afd4
...
...
@@ -716,9 +716,6 @@ class Host(models.Model):
proto
=
proto
,
nat
=
False
,
action
=
'accept'
,
host
=
self
,
foreign_network
=
vg
)
if
self
.
behind_nat
:
if
public
<
1024
:
raise
ValidationError
(
_
(
"Only ports above 1024 can be used."
))
rule
.
nat_external_port
=
public
rule
.
nat
=
True
rule
.
full_clean
()
...
...
circle/firewall/tests/test_firewall.py
View file @
bad4afd4
...
...
@@ -313,11 +313,6 @@ class ReloadTestCase(TestCase):
new_rules
=
h
.
rules
.
count
()
self
.
assertEqual
(
new_rules
,
old_rules
)
def
test_host_add_port_w_validationerror
(
self
):
h
=
self
.
h1
self
.
assertRaises
(
ValidationError
,
h
.
add_port
,
'tcp'
,
public
=
1000
,
private
=
22
)
def
test_periodic_task
(
self
):
# TODO
with
patch
(
'firewall.tasks.local_tasks.cache'
)
as
cache
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment