Package org.jboss.arquillian.test.spi

Examples of org.jboss.arquillian.test.spi.TestClass


     * <p>Tests the {@link CustomRemoteApplicationContextProducer#supports(org.jboss.arquillian.test.spi.TestClass)}
     * method.</p>
     */
    @Test
    public void testSupportsFalse() {
        TestClass testClass = new TestClass(PlainClass.class);

        assertFalse("Class without annotations shouldn't be supported.", instance.supports(testClass));
    }
View Full Code Here


    /**
     * <p>Tests the {@link CustomRemoteApplicationContextProducer#supports(TestClass)} method.</p>
     */
    @Test
    public void testSupportsTrue() {
        TestClass testClass = new TestClass(CustomApplicationContextClass.class);

        assertTrue("Class should be supported.", instance.supports(testClass));
    }
View Full Code Here

    /**
     * <p>Tests the {@link CustomRemoteApplicationContextProducer#createApplicationContext(TestClass)} method.</p>
     */
    @Test
    public void testCreateApplicationContextDefault() {
        TestClass testClass = new TestClass(CustomApplicationContextClass.class);

        TestScopeApplicationContext result = instance.createApplicationContext(testClass);

        assertNotNull("The result was null.", result);
        assertTrue("The application context should be marked as closable.", result.isClosable());
View Full Code Here

     * @throws Exception if any error occurs
     */
    @Test(expected = RuntimeException.class)
    public void testCreateApplicationContextNull() throws Exception {

        TestClass testClass = new TestClass(CustomNullApplicationContextClass.class);

        instance.createApplicationContext(testClass);
    }
View Full Code Here

     * @throws Exception if any error occurs
     */
    @Test(expected = RuntimeException.class)
    public void testCreateApplicationContextMultipleMethods() throws Exception {

        TestClass testClass = new TestClass(CustomNullApplicationContextClass.class);

        instance.createApplicationContext(testClass);
    }
View Full Code Here

     * @throws Exception if any error occurs
     */
    @Test(expected = ClassCastException.class)
    public void testCreateApplicationContextIncorrectMethodContract() throws Exception {

        TestClass testClass = new TestClass(CustomInvalidApplicationContextClass.class);

        instance.createApplicationContext(testClass);
    }
View Full Code Here

     * @throws Exception if any error occurs
     */
    @Test(expected = RuntimeException.class)
    public void testCreateApplicationContextErrorPropagation() throws Exception {

        TestClass testClass = new TestClass(CustomExceptionApplicationContextClass.class);

        instance.createApplicationContext(testClass);
    }
View Full Code Here

    /**
     * <p>Tests the {@link XmlClientApplicationContextProducer#supports(TestClass)} method.</p>
     */
    @Test
    public void testSupportsFalse() {
        TestClass testClass = new TestClass(PlainClass.class);

        assertFalse("Class without annotations shouldn't be supported.", instance.supports(testClass));
    }
View Full Code Here

    /**
     * <p>Tests the {@link XmlClientApplicationContextProducer#supports(TestClass)} method.</p>
     */
    @Test
    public void testSupportsTrue() {
        TestClass testClass = new TestClass(ClientXmlAnnotatedClass.class);

        assertTrue("Class should be supported.", instance.supports(testClass));
    }
View Full Code Here

    /**
     * <p>Tests the {@link XmlClientApplicationContextProducer#createApplicationContext(TestClass)} method.</p>
     */
    @Test
    public void testCreateApplicationContextDefault() {
        TestClass testClass = new TestClass(ClientXmlAnnotatedClass.class);

        TestScopeApplicationContext result = instance.createApplicationContext(testClass);

        assertNotNull("The result was null.", result);
        assertTrue("The application context should be marked as closable.", result.isClosable());
View Full Code Here

TOP

Related Classes of org.jboss.arquillian.test.spi.TestClass

Copyright © 2018 www.massapicom. 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.