Package harness

Examples of harness.Harness


        addTest(setupHarness());
    }
   
    private TestHarness setupHarness() throws Exception {
        Unmarshaller unm;
        Harness harness;
        TestHarness testApp;
        Mapping mapping;

        unm = new Unmarshaller(Harness.class);
        mapping = new Mapping();
        mapping.loadMapping(Main.class.getResource("harness/mapping.xml"));
        unm.setMapping(mapping);
        if (_testRes != null) {
            harness = (Harness) unm.unmarshal(new InputStreamReader(
                    Main.class.getResourceAsStream(_testRes)));
        } else if (_testFile != null) {
            harness = (Harness) unm.unmarshal(new InputStreamReader(
                    new FileInputStream(_testFile)));
        } else if (_testUrl != null) {
            harness = (Harness) unm.unmarshal(new InputStreamReader(
                    (new URL(_testUrl)).openStream()));
        } else {
            harness = (Harness) unm.unmarshal(new InputStreamReader(
                    Main.class.getResourceAsStream(DEFAULT_FILE)));
        }
        testApp = harness.createTestHarness(_testBranchs);
        return testApp;
    }
View Full Code Here

TOP

Related Classes of harness.Harness

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.