Search in sources :

Example 6 with Navigate

use of com.aire.ux.test.Navigate in project aire-components by aire-ux.

the class TopLevelVaadinTestCaseTest method ensureTestMethodGeneratesFrameWithCurrentMethod2.

@ViewTest
@Navigate("test")
@Routes(scanPackage = "com.aire.ux.test.vaadin.scenarios.classroutes")
void ensureTestMethodGeneratesFrameWithCurrentMethod2(@Select ClassScenarioRouteLayout layout) throws NoSuchMethodException {
    val method = Frames.resolveCurrentFrame().getContext().getTestMethod();
    assertTrue(method.isPresent());
    val m = method.get();
    assertEquals(m, TopLevelVaadinTestCaseTest.class.getDeclaredMethod("ensureTestMethodGeneratesFrameWithCurrentMethod2", ClassScenarioRouteLayout.class));
}
Also used : lombok.val(lombok.val) ClassScenarioRouteLayout(com.aire.ux.test.vaadin.scenarios.classroutes.ClassScenarioRouteLayout) ViewTest(com.aire.ux.test.ViewTest) Navigate(com.aire.ux.test.Navigate) Routes(com.aire.ux.test.Routes)

Example 7 with Navigate

use of com.aire.ux.test.Navigate in project aire-components by aire-ux.

the class PluginTabViewTest method ensurePluginTabViewIsInjectable.

@ViewTest
@Navigate("zephyr/management/modules/list")
void ensurePluginTabViewIsInjectable(@Context TestContext $) {
    val view = $.selectFirst("aire-tab-panel", TabPanel.class);
    assertTrue(view.isPresent());
}
Also used : lombok.val(lombok.val) ViewTest(com.aire.ux.test.ViewTest) Navigate(com.aire.ux.test.Navigate)

Aggregations

Navigate (com.aire.ux.test.Navigate)7 ViewTest (com.aire.ux.test.ViewTest)7 lombok.val (lombok.val)7 Routes (com.aire.ux.test.Routes)5 MainView (com.aire.ux.spring.test.scenario1.MainView)1 Scenario1Configuration (com.aire.ux.spring.test.scenario1.Scenario1Configuration)1 TestService (com.aire.ux.spring.test.scenario1.TestService)1 AireTest (com.aire.ux.test.AireTest)1 Context (com.aire.ux.test.Context)1 Select (com.aire.ux.test.Select)1 TestContext (com.aire.ux.test.TestContext)1 EnableSpring (com.aire.ux.test.spring.EnableSpring)1 ClassScenarioRouteLayout (com.aire.ux.test.vaadin.scenarios.classroutes.ClassScenarioRouteLayout)1 Button (com.vaadin.flow.component.button.Button)1 Element (com.vaadin.flow.dom.Element)1 Inject (javax.inject.Inject)1 Assertions.assertEquals (org.junit.jupiter.api.Assertions.assertEquals)1 Assertions.assertNotNull (org.junit.jupiter.api.Assertions.assertNotNull)1 Order (org.junit.jupiter.api.Order)1 Test (org.junit.jupiter.api.Test)1