Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
LOFAR
Manage
Activity
Members
Labels
Plan
Issues
Wiki
Jira issues
Open Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review 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
RadioObservatory
LOFAR
Commits
0620a2d9
Commit
0620a2d9
authored
8 years ago
by
Jorrit Schaap
Browse files
Options
Downloads
Patches
Plain Diff
Task #10811: fixed test
parent
7deb4379
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
SAS/ResourceAssignment/ResourceAssignmentDatabase/tests/t_radb.py
+6
-9
6 additions, 9 deletions
...urceAssignment/ResourceAssignmentDatabase/tests/t_radb.py
with
6 additions
and
9 deletions
SAS/ResourceAssignment/ResourceAssignmentDatabase/tests/t_radb.py
+
6
−
9
View file @
0620a2d9
...
...
@@ -212,16 +212,13 @@ class ResourceAssignmentDatabaseTest(unittest.TestCase):
# triggers in place?
def
test_insert_specification_swaps_startendtimes_if_needed
(
self
):
#when inserting spec with start>endtime, should raise error
with
self
.
assertRaises
(
psycopg2
.
InternalError
)
as
context
:
# insert spec
starttime
=
'
2017-05-10 12:00:00
'
endtime
=
'
2017-05-10 10:00:00
'
ident
=
self
.
_insert_test_spec
(
starttime
=
starttime
,
endtime
=
endtime
)
# check endtime in db is old starttime
query
=
"
SELECT endtime FROM resource_allocation.specification WHERE id=%s
"
%
ident
fetch
=
self
.
_execute_query
(
query
,
fetch
=
True
)
self
.
assertTrue
(
parser
.
parse
(
starttime
)
==
fetch
[
0
][
0
])
# notifications in place?
def
test_insert_task_triggers_notification
(
self
):
# insert specification to not raise INtegrityError
...
...
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