8196338: [TEST_BUG] sanity/client/SwingSet/src/TextFieldDemoTest.java Failed with timeout
Reviewed-by: ssadetsky
--- a/test/jdk/sanity/client/SwingSet/src/TextFieldDemoTest.java Thu Feb 15 17:20:57 2018 -0800
+++ b/test/jdk/sanity/client/SwingSet/src/TextFieldDemoTest.java Fri Feb 16 18:06:23 2018 +0530
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2010, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2010, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -101,6 +101,7 @@
JButtonOperator jbo = new JButtonOperator(containerOperator, GO);
JLabelOperator dowLabel = new JLabelOperator(containerOperator);
Calendar calendar = Calendar.getInstance(Locale.ENGLISH);
+ calendar.setTime((Date) getUIValue(jtfo, jtf -> ((JFormattedTextField)jtf).getValue()));
// Check default date Day of the Week
jbo.push();