Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
openbis
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
sispub
openbis
Commits
4c64d419
Commit
4c64d419
authored
13 years ago
by
tpylak
Browse files
Options
Downloads
Patches
Plain Diff
LMS-2459 fix unit tests
SVN: 22674
parent
8a424125
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
openbis/sourceTest/java/ch/systemsx/cisd/openbis/generic/server/business/bo/dynamic_property/DynamicPropertyEvaluatorTest.java
+8
-3
8 additions, 3 deletions
...ess/bo/dynamic_property/DynamicPropertyEvaluatorTest.java
with
8 additions
and
3 deletions
openbis/sourceTest/java/ch/systemsx/cisd/openbis/generic/server/business/bo/dynamic_property/DynamicPropertyEvaluatorTest.java
+
8
−
3
View file @
4c64d419
...
...
@@ -243,7 +243,9 @@ public class DynamicPropertyEvaluatorTest extends AbstractBOTest
final
SamplePropertyPE
dpMaterial
=
createDynamicSampleProperty
(
dynamicPropertyType
,
script1
);
final
ScriptPE
scriptError1
=
createScript
(
"se1"
,
"'fake_material'"
);
final
MaterialIdentifier
fakeCodeIdentifier
=
new
MaterialIdentifier
(
"fake_material"
,
materialTypeCode
);
final
ScriptPE
scriptError1
=
createScript
(
"se1"
,
"'"
+
fakeCodeIdentifier
.
getCode
()
+
"'"
);
final
PropertyTypePE
dynamicPropertyTypeError1
=
createPropertyType
(
"dpMaterialError1"
,
DataTypeCode
.
MATERIAL
);
dynamicPropertyTypeError1
.
setMaterialType
(
materialType
);
...
...
@@ -278,6 +280,10 @@ public class DynamicPropertyEvaluatorTest extends AbstractBOTest
context
.
checking
(
new
Expectations
()
{
{
one
(
materialDAO
).
tryFindMaterial
(
sessionProvider
.
getSession
(),
fakeCodeIdentifier
);
will
(
returnValue
(
null
));
one
(
materialDAO
).
tryFindMaterial
(
sessionProvider
.
getSession
(),
new
MaterialIdentifier
(
material
.
getCode
(),
materialTypeCode
));
will
(
returnValue
(
material
));
...
...
@@ -302,8 +308,7 @@ public class DynamicPropertyEvaluatorTest extends AbstractBOTest
assertEquals
(
material
,
dpMaterial
.
getMaterialValue
());
final
String
expectedDpMaterialError1Value
=
expectedErrorMessage
(
"Material specification 'fake_material' has improper format. "
+
"Expected '<CODE> (<TYPE>)'."
);
expectedErrorMessage
(
"No material could be found for identifier 'fake_material (M_TYPE)'."
);
assertEquals
(
expectedDpMaterialError1Value
,
dpMaterialError1
.
getValue
());
assertEquals
(
null
,
dpMaterialError1
.
getVocabularyTerm
());
...
...
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