Package org.jboss.arquillian.test.spi

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


    /**
     * <p>Tests the {@link AnnotationRemoteApplicationContextProducer#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 AnnotationRemoteApplicationContextProducer#supports(TestClass)} method.</p>
     */
    @Test
    public void testSupportsTrue1() {
        TestClass testClass = new TestClass(ClassesAnnotatedClass.class);

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

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

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

     *
     * @throws Exception if any error occurs
     */
    @Test
    public void testCreateApplicationContextCustomContextClassesConfiguration() throws Exception {
        TestClass testClass = new TestClass(ClassesAnnotatedClass.class);

        Map<String, String> properties = new HashMap<String, String>();
        properties.put("customAnnotationContextClass",
                "org.springframework.context.annotation.AnnotationConfigApplicationContext");
        remoteConfiguration = new SpringIntegrationConfiguration(properties);
View Full Code Here

     *
     * @throws Exception if any error occurs
     */
    @Test(expected = RuntimeException.class)
    public void testCreateApplicationContextCustomContextClassesConfigurationError() throws Exception {
        TestClass testClass = new TestClass(ClassesAnnotatedClass.class);

        Map<String, String> properties = new HashMap<String, String>();
        properties.put("customAnnotationContextClass",
                "invalid class name");
        remoteConfiguration = new SpringIntegrationConfiguration(properties);
View Full Code Here

     *
     * @throws Exception if any error occurs
     */
    @Test
    public void testCreateApplicationContextCustomContextPackagesConfiguration() throws Exception {
        TestClass testClass = new TestClass(PackagesAnnotatedClass.class);

        Map<String, String> properties = new HashMap<String, String>();
        properties.put("customAnnotationContextClass",
                "org.springframework.context.annotation.AnnotationConfigApplicationContext");
        remoteConfiguration = new SpringIntegrationConfiguration(properties);
View Full Code Here

     *
     * @throws Exception if any error occurs
     */
    @Test(expected = RuntimeException.class)
    public void testCreateApplicationContextCustomContextPackagesConfigurationError() throws Exception {
        TestClass testClass = new TestClass(PackagesAnnotatedClass.class);

        Map<String, String> properties = new HashMap<String, String>();
        properties.put("customAnnotationContextClass",
                "invalid class name");
        remoteConfiguration = new SpringIntegrationConfiguration(properties);
View Full Code Here

    /**
     * <p>Tests the {@link AnnotationRemoteApplicationContextProducer#createApplicationContext(TestClass)} method.</p>
     */
    @Test
    public void testCreateApplicationContextCustomContextClasses() {
        TestClass testClass = new TestClass(AnnotatedClassesCustomContextClass.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 testCreateApplicationContextCustomContextClassesConfigurationAndAnnotation() throws Exception {
        TestClass testClass = new TestClass(AnnotatedClassesCustomContextClass.class);

        Map<String, String> properties = new HashMap<String, String>();
        properties.put("customAnnotationContextClass",
                "invalid class name");
        remoteConfiguration = new SpringIntegrationConfiguration(properties);
View Full Code Here

    /**
     * <p>Tests the {@link AnnotationRemoteApplicationContextProducer#createApplicationContext(TestClass)} method.</p>
     */
    @Test
    public void testCreateApplicationContextCustomContextPackages() {
        TestClass testClass = new TestClass(AnnotatedPackagesCustomContextClass.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.