File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
app/display/runtime/src/test/java/org/csstudio/display/builder/runtime/test Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 11package org .csstudio .display .builder .runtime .test ;
22
3- import static org .junit .Assert .assertTrue ;
3+ import static org .hamcrest .CoreMatchers .equalTo ;
4+ import static org .hamcrest .MatcherAssert .assertThat ;
45import static org .junit .jupiter .api .Assertions .fail ;
56
67import java .util .ArrayList ;
@@ -37,7 +38,7 @@ public void testWriteAction()
3738 //PVUtil.writePV(pv_name, initValue, 0);
3839 double readValue = PVUtil .getDouble (pv );
3940 //Test in standard way
40- assertTrue ( "Write succeed" , readValue == initValue );
41+ assertThat ( readValue , equalTo ( initValue ) );
4142
4243 //Test with WidgetRuntime (write Action)
4344 ActionButtonWidget widget = new ActionButtonWidget ();
@@ -63,7 +64,8 @@ public void testWriteAction()
6364 //Test the new value
6465 readValue = PVUtil .getDouble (pv );
6566 //Test if the new value is ok
66- assertTrue ("Write succeed" , readValue == newValue );
67+ assertThat (readValue , equalTo (newValue ));
68+
6769 } catch (Exception e ) {
6870 e .printStackTrace ();
6971 fail (e );
You can’t perform that action at this time.
0 commit comments