Package org.apache.cxf.javascript.JavascriptTestUtilities

Examples of org.apache.cxf.javascript.JavascriptTestUtilities.Notifier.waitForJavascript()


                                                   testUtilities.javaToJS(Double.valueOf(17.0)),
                                                   testUtilities.javaToJS(Float.valueOf((float)111.0)),
                                                   testUtilities.javaToJS(Integer.valueOf(142)),
                                                   testUtilities.javaToJS(Long.valueOf(1240000)),
                                                   "This is the cereal shot from gnus");
                boolean notified = notifier.waitForJavascript(1000 * 10);
                assertTrue(notified);
                Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
                assertNull(errorStatus);
                String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
                assertNull(errorText);
View Full Code Here


                                                                       .valueOf((float)11.0)), testUtilities
                                                                       .javaToJS(Integer.valueOf(42)),
                                                                   testUtilities.javaToJS(Long
                                                                       .valueOf(240000)),
                                                                   "This is the cereal shot from guns");
                boolean notified = notifier.waitForJavascript(1000 * 10);
                assertTrue(notified);
                Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
                assertNull(errorStatus);
                String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
                assertNull(errorText);
View Full Code Here

        testUtilities.runInsideContext(Void.class, new JSRunnable<Void>() {

            public Void run(Context context) {
                Notifier notifier = testUtilities.rhinoCallConvert("testInheritance", Notifier.class,
                                                                   testUtilities.javaToJS(getAddress()));
                boolean notified = notifier.waitForJavascript(1000 * 10);
                assertTrue(notified);
                SimpleDocLitWrappedImpl impl = (SimpleDocLitWrappedImpl)rawImplementor;
                assertEquals("less", impl.getLastInheritanceTestDerived().getName());
                return null;
            }
View Full Code Here

                                                   testUtilities.javaToJS(Double.valueOf(17.0)),
                                                   testUtilities.javaToJS(Float.valueOf((float)111.0)),
                                                   testUtilities.javaToJS(Integer.valueOf(142)),
                                                   testUtilities.javaToJS(Long.valueOf(1240000)),
                                                   null);
                boolean notified = notifier.waitForJavascript(1000 * 10);
                assertTrue(notified);
                Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
                assertNull(errorStatus);
                String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
                assertNull(errorText);
View Full Code Here

    private Void returnAny1(Context context) {
        Notifier notifier =
            testUtilities.rhinoCallConvert("testAny1ToClientChalk", Notifier.class,
                                           testUtilities.javaToJS(getAddress()));
       
        boolean notified = notifier.waitForJavascript(1000 * 10);
        assertTrue(notified);
        Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
        assertNull(errorStatus);
        String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
        assertNull(errorText);
View Full Code Here

        testUtilities.rhinoCallExpectingExceptionInContext("SYNTAX_ERR", "testNonHttp");
        testUtilities.rhinoCallExpectingExceptionInContext("INVALID_STATE_ERR", "testSendNotOpenError");
        testUtilities.rhinoCallInContext("testStateNotificationSync");
        Notifier notifier = testUtilities.rhinoCallConvert("testAsyncHttpFetch1", Notifier.class);
        testUtilities.rhinoCallInContext("testAsyncHttpFetch2");
        boolean notified = notifier.waitForJavascript(10000);
        assertTrue(notified);
        assertEquals("HEADERS_RECEIVED", Boolean.TRUE,
                     testUtilities.rhinoEvaluateConvert("asyncGotHeadersReceived", Boolean.class));
        assertEquals("LOADING", Boolean.TRUE,
                     testUtilities.rhinoEvaluateConvert("asyncGotLoading", Boolean.class));
View Full Code Here

        Notifier notifier =
            testUtilities.rhinoCallConvert("beanFunctionTest", Notifier.class,
                                           testUtilities.javaToJS(getAddress()),
                                           jsBean1,
                                           jsBeanArray);
        boolean notified = notifier.waitForJavascript(1000 * 10);
        assertTrue(notified);
        Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
        assertNull(errorStatus);
        String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
        assertNull(errorText);
View Full Code Here

        LOG.info("About to call compliant" + getAddress());
        Notifier notifier =
            testUtilities.rhinoCallConvert("compliantTest", Notifier.class,
                                           testUtilities.javaToJS(getAddress()),
                                           jsBean1);
        boolean notified = notifier.waitForJavascript(1000 * 10);
        assertTrue(notified);
        Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
        assertNull(errorStatus);
        String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
        assertNull(errorText);
View Full Code Here

        LOG.info("About to call actionMethod" + getAddress());
        Notifier notifier =
            testUtilities.rhinoCallConvert("actionMethodTest", Notifier.class,
                                           testUtilities.javaToJS(getAddress()),
                                           "wrong");
        boolean notified = notifier.waitForJavascript(1000 * 10);
        assertTrue(notified);
        Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
        assertNull(errorStatus);
        String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
        assertNull(errorText);
View Full Code Here

        LOG.info("About to call compliantNoArgs " + getAddress());
        Notifier notifier =
            testUtilities.rhinoCallConvert("compliantNoArgsTest", Notifier.class,
                                           testUtilities.javaToJS(getAddress()));

        boolean notified = notifier.waitForJavascript(1000 * 10);
        assertTrue(notified);
        Integer errorStatus = testUtilities.rhinoEvaluateConvert("globalErrorStatus", Integer.class);
        assertNull(errorStatus);
        String errorText = testUtilities.rhinoEvaluateConvert("globalErrorStatusText", String.class);
        assertNull(errorText);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.