package haskell.prelude;

import junit.framework.TestCase;

public class FunctionTest extends TestCase {

    public void testFunction() {
        Function<Int, Int> f = new Function<Int, Int>() {
            @Override
            public Int apply(Int x) {
                return Int.valueOf(x.value() + 1);
            }
        };
        Int result = f.apply(Int.valueOf(2));
        System.out.println(result);
        assertEquals(3, result.value());
    }

}
