Package com.asakusafw.testdriver.core

Examples of com.asakusafw.testdriver.core.DataModelReflection


            @Override
            public DataModelSource apply(final DataModelSource source) {
                return new DataModelSource() {
                    @Override
                    public DataModelReflection next() throws IOException {
                        DataModelReflection next = source.next();
                        if (next == null || DEFINITION.toObject(next).toString().equals("Hello2")) {
                            return next;
                        }
                        return next;
                    }
View Full Code Here


            throw new AssertionError(e);
        }
    }

    private Simple next(DataModelSource source) throws IOException {
        DataModelReflection next = source.next();
        if (next != null) {
            return SIMPLE.toObject(next);
        }
        return null;
    }
View Full Code Here

                "C_DATETIME"
                );
    }

    private Simple next(DataModelSource source) throws IOException {
        DataModelReflection next = source.next();
        if (next != null) {
            return SIMPLE.toObject(next);
        }
        return null;
    }
View Full Code Here

    private <T> List<T> drain(DataModelDefinition<T> def, DataModelSource source) throws IOException {
        try {
            List<DataModelReflection> retrieved = new ArrayList<DataModelReflection>();
            while (true) {
                DataModelReflection next = source.next();
                if (next == null) {
                    break;
                }
                retrieved.add(next);
            }
View Full Code Here

        putTextRaw("target/testing/hello", "Hello, world!\nThis is a test.\n".getBytes("UTF-8"));

        MockTextDefinition definition = new MockTextDefinition();
        DataModelSource result = retriever.createSource(definition, exporter, EMPTY);
        try {
            DataModelReflection ref;
            ref = result.next();
            assertThat(ref, is(not(nullValue())));
            assertThat(definition.toObject(ref), is(new Text("Hello, world!")));

            ref = result.next();
View Full Code Here

        putTextSequenceFile("target/testing/hello", "Hello, world!", "This is a test.");

        MockTextDefinition definition = new MockTextDefinition();
        DataModelSource result = retriever.createSource(definition, exporter, EMPTY);
        try {
            DataModelReflection ref;
            ref = result.next();
            assertThat(ref, is(not(nullValue())));
            assertThat(definition.toObject(ref), is(new Text("Hello, world!")));

            ref = result.next();
View Full Code Here

TOP

Related Classes of com.asakusafw.testdriver.core.DataModelReflection

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.