// Path: bte-core/src/main/java/gr/ekt/bte/exceptions/BadTransformationSpec.java
// public class BadTransformationSpec extends Exception {
//     public BadTransformationSpec() {
//         super();
//     }
// 
//     public BadTransformationSpec(String message) {
//         super(message);
//     }
// 
//     private static final long serialVersionUID = 2L;
// }
// 
// Path: bte-core/src/main/java/gr/ekt/bte/exceptions/MalformedSourceException.java
// public class MalformedSourceException extends Exception {
// 
//     public MalformedSourceException(String message) {
//         super(message);
//     }
// 
//     private static final long serialVersionUID = 1L;
// }


import static org.junit.Assert.*;
import gr.ekt.bte.exceptions.BadTransformationSpec;
import gr.ekt.bte.exceptions.MalformedSourceException;
import org.junit.Before;
import org.junit.Test;
    public void testTransform() {
        try {
            TransformationEngine te = new TransformationEngine(dl, og, empty_workflow);
            TransformationSpec spec = new TransformationSpec();
            spec.setNumberOfRecords(100);

            TransformationResult res = null;
            try {
                res = te.transform(spec);
            } catch(BadTransformationSpec e) {
                fail(e.getMessage());
            }

            assertEquals(100, res.getOutput().size());
            assertEquals(100, res.getLastLog().getFirstUnexaminedRecord());
            assertFalse(res.getLastLog().getEndOfInput());

            spec.setOffset(res.getLastLog().getFirstUnexaminedRecord());
            try {
                res = te.transform(spec);
            } catch(BadTransformationSpec e) {
                fail(e.getMessage());
            }

            assertEquals(100, res.getOutput().size());
            assertEquals(200, res.getLastLog().getFirstUnexaminedRecord());
            assertFalse(res.getLastLog().getEndOfInput());

            spec.setOffset(res.getLastLog().getFirstUnexaminedRecord());
            spec.setNumberOfRecords(350);
// Path: bte-core/src/main/java/gr/ekt/bte/exceptions/BadTransformationSpec.java
// public class BadTransformationSpec extends Exception {
//     public BadTransformationSpec() {
//         super();
//     }
// 
//     public BadTransformationSpec(String message) {
//         super(message);
//     }
// 
//     private static final long serialVersionUID = 2L;
// }
// 
// Path: bte-core/src/main/java/gr/ekt/bte/exceptions/MalformedSourceException.java
// public class MalformedSourceException extends Exception {
// 
//     public MalformedSourceException(String message) {
//         super(message);
//     }
// 
//     private static final long serialVersionUID = 1L;
// }


// Path: bte-core/src/test/java/gr/ekt/bte/core/TransformationEngineTest.java
import static org.junit.Assert.*;
import gr.ekt.bte.exceptions.BadTransformationSpec;
import gr.ekt.bte.exceptions.MalformedSourceException;
import org.junit.Before;
import org.junit.Test;

    public void testTransform() {
        try {
            TransformationEngine te = new TransformationEngine(dl, og, empty_workflow);
            TransformationSpec spec = new TransformationSpec();
            spec.setNumberOfRecords(100);

            TransformationResult res = null;
            try {
                res = te.transform(spec);
            } catch(BadTransformationSpec e) {
                fail(e.getMessage());
            }

            assertEquals(100, res.getOutput().size());
            assertEquals(100, res.getLastLog().getFirstUnexaminedRecord());
            assertFalse(res.getLastLog().getEndOfInput());

            spec.setOffset(res.getLastLog().getFirstUnexaminedRecord());
            try {
                res = te.transform(spec);
            } catch(BadTransformationSpec e) {
                fail(e.getMessage());
            }

            assertEquals(100, res.getOutput().size());
            assertEquals(200, res.getLastLog().getFirstUnexaminedRecord());
            assertFalse(res.getLastLog().getEndOfInput());

            spec.setOffset(res.getLastLog().getFirstUnexaminedRecord());
            spec.setNumberOfRecords(350);
            try {