Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
minerva
core
Commits
8ff3c1e0
Commit
8ff3c1e0
authored
Apr 20, 2021
by
Piotr Gawron
Browse files
old test removed
parent
961a437d
Pipeline
#40158
passed with stage
in 24 minutes and 46 seconds
Changes
2
Pipelines
1
Expand all
Hide whitespace changes
Inline
Side-by-side
frontend-js/package-lock.json
View file @
8ff3c1e0
This diff is collapsed.
Click to expand it.
frontend-js/src/test/js/map/overlay/DrugDbOverlay-test.js
View file @
8ff3c1e0
...
...
@@ -44,43 +44,6 @@ describe('DrugDbOverlay', function () {
assert
.
equal
(
elements
.
length
,
1
);
});
});
it
(
"
check if info window updated
"
,
function
()
{
helper
.
setUrl
(
"
http://test-page/?id=drug_target_sample
"
);
var
map
,
searchDb
,
alias
,
marker
,
infoWindow
;
var
ie
=
new
IdentifiedElement
({
id
:
436152
,
modelId
:
20637
,
type
:
'
ALIAS
'
});
return
ServerConnector
.
getProject
(
"
drug_target_sample
"
).
then
(
function
(
project
)
{
map
=
helper
.
createCustomMap
(
project
);
searchDb
=
helper
.
createDrugDbOverlay
(
map
);
return
map
.
getModel
().
getByIdentifiedElement
(
ie
);
}).
then
(
function
(
result
)
{
alias
=
result
;
marker
=
map
.
getMapCanvas
().
createMarker
({
icon
:
"
empty.png
"
,
position
:
new
Point
(
0
,
0
)});
return
map
.
openInfoWindowForIdentifiedElement
(
ie
,
marker
)
}).
then
(
function
(
result
)
{
infoWindow
=
result
;
assert
.
notOk
(
infoWindow
.
getContent
().
innerHTML
.
indexOf
(
"
NADH
"
)
>=
0
);
return
searchDb
.
searchByQuery
(
"
NADH
"
);
}).
then
(
function
(
drugs
)
{
assert
.
equal
(
drugs
.
length
,
1
);
assert
.
equal
(
searchDb
.
getQueries
().
length
,
1
);
return
searchDb
.
getElementsByQuery
(
searchDb
.
getQueries
()[
0
]);
}).
then
(
function
(
elements
)
{
assert
.
ok
(
elements
.
length
>
1
);
return
searchDb
.
getIdentifiedElements
();
}).
then
(
function
(
elements
)
{
assert
.
ok
(
infoWindow
.
getContent
().
innerHTML
.
indexOf
(
"
NADH
"
)
>=
0
);
assert
.
equal
(
elements
.
length
,
1
);
}).
finally
(
function
(){
return
map
.
destroy
();
});
});
});
it
(
"
searchNamesByTarget
"
,
function
()
{
...
...
Write
Preview
Supports
Markdown
0%
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!
Cancel
Please
register
or
sign in
to comment