Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Gutyán Gábor
/
circlestack
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
5c4c6d14
authored
Oct 27, 2014
by
Guba Sándor
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tests: fix redirects to permission denied (403)
parent
69cf4530
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
circle/dashboard/tests/test_views.py
+3
-3
No files found.
circle/dashboard/tests/test_views.py
View file @
5c4c6d14
...
...
@@ -637,7 +637,7 @@ class NodeDetailTest(LoginMixin, TestCase):
c
=
Client
()
self
.
login
(
c
,
'user1'
)
response
=
c
.
get
(
'/dashboard/node/25555/'
)
self
.
assertEqual
(
response
.
status_code
,
302
)
self
.
assertEqual
(
response
.
status_code
,
403
)
def
test_anon_node_page
(
self
):
c
=
Client
()
...
...
@@ -667,7 +667,7 @@ class NodeDetailTest(LoginMixin, TestCase):
node
=
Node
.
objects
.
get
(
pk
=
1
)
old_name
=
node
.
name
response
=
c
.
post
(
"/dashboard/node/1/"
,
{
'new_name'
:
'test1235'
})
self
.
assertEqual
(
response
.
status_code
,
302
)
self
.
assertEqual
(
response
.
status_code
,
403
)
self
.
assertEqual
(
Node
.
objects
.
get
(
pk
=
1
)
.
name
,
old_name
)
def
test_permitted_set_name
(
self
):
...
...
@@ -721,7 +721,7 @@ class NodeDetailTest(LoginMixin, TestCase):
c
=
Client
()
self
.
login
(
c
,
"user2"
)
response
=
c
.
post
(
"/dashboard/node/1/"
,
{
'to_remove'
:
traitid
})
self
.
assertEqual
(
response
.
status_code
,
302
)
self
.
assertEqual
(
response
.
status_code
,
403
)
self
.
assertEqual
(
Node
.
objects
.
get
(
pk
=
1
)
.
traits
.
count
(),
trait_count
)
def
test_permitted_remove_trait
(
self
):
...
...
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