SciPost Code Repository
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
SciPost
Manage
Activity
Members
Labels
Plan
Issues
118
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
SciPost
SciPost
Commits
fef1a8ac
Commit
fef1a8ac
authored
7 years ago
by
Jorran de Wit
Browse files
Options
Downloads
Patches
Plain Diff
Fix outdated tests
parent
d927071c
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
scipost/models.py
+0
-1
0 additions, 1 deletion
scipost/models.py
submissions/test_views.py
+5
-5
5 additions, 5 deletions
submissions/test_views.py
with
5 additions
and
6 deletions
scipost/models.py
+
0
−
1
View file @
fef1a8ac
...
...
@@ -8,7 +8,6 @@ from django.contrib.postgres.fields import ArrayField
from
django.db
import
models
from
django.template
import
Template
,
Context
from
django.utils
import
timezone
from
django.utils.safestring
import
mark_safe
from
django_countries.fields
import
CountryField
...
...
This diff is collapsed.
Click to expand it.
submissions/test_views.py
+
5
−
5
View file @
fef1a8ac
...
...
@@ -7,13 +7,12 @@ from django.test import Client
from
common.helpers
import
random_arxiv_identifier_without_version_number
from
common.helpers.test
import
add_groups_and_permissions
from
scipost.factories
import
ContributorFactory
# from scipost.models import Contributor
from
.constants
import
STATUS_UNASSIGNED
from
.factories
import
UnassignedSubmissionFactory
,
EICassignedSubmissionFactory
,
\
ResubmittedSubmissionFactory
,
ResubmissionFactory
,
\
PublishedSubmissionFactory
from
.forms
import
SubmissionForm
,
SubmissionIdentifierForm
from
.forms
import
Request
SubmissionForm
,
SubmissionIdentifierForm
from
.models
import
Submission
# This is content of a real arxiv submission. As long as it isn't published it should
...
...
@@ -87,7 +86,7 @@ class PrefillUsingIdentifierTest(BaseContributorTestCase):
{
'
identifier
'
:
TEST_SUBMISSION
[
'
arxiv_identifier_w_vn_nr
'
]})
self
.
assertEqual
(
response
.
status_code
,
200
)
self
.
assertIsInstance
(
response
.
context
[
'
form
'
],
SubmissionForm
)
self
.
assertIsInstance
(
response
.
context
[
'
form
'
],
Request
SubmissionForm
)
self
.
assertIsInstance
(
response
.
context
[
'
identifierform
'
],
SubmissionIdentifierForm
)
self
.
assertTrue
(
response
.
context
[
'
identifierform
'
].
is_valid
())
...
...
@@ -138,7 +137,6 @@ class SubmitManuscriptTest(BaseContributorTestCase):
'
submission_type
'
:
'
Article
'
,
'
domain
'
:
'
T
'
})
params
[
'
metadata
'
]
=
json
.
dumps
(
params
[
'
metadata
'
],
separators
=
(
'
,
'
,
'
:
'
))
# Submit new Submission form
response
=
client
.
post
(
reverse
(
'
submissions:submit_manuscript
'
),
params
)
...
...
@@ -179,7 +177,6 @@ class SubmitManuscriptTest(BaseContributorTestCase):
'
submission_type
'
:
'
Article
'
,
'
domain
'
:
'
T
'
})
params
[
'
metadata
'
]
=
json
.
dumps
(
params
[
'
metadata
'
],
separators
=
(
'
,
'
,
'
:
'
))
# Submit new Submission form
response
=
client
.
post
(
reverse
(
'
submissions:submit_manuscript
'
),
params
)
...
...
@@ -246,3 +243,6 @@ class SubmissionListTest(BaseContributorTestCase):
returned_submissions_ids
.
sort
()
visible_submission_ids
.
sort
()
self
.
assertListEqual
(
returned_submissions_ids
,
visible_submission_ids
)
# class SubmitReportTest
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment