@@ -0,0 +1,2815 @@
+/**%0A * The MIT License (MIT)%0A *%0A * Copyright (c) 2017-2018 Yegor Bugayenko%0A *%0A * Permission is hereby granted, free of charge, to any person obtaining a copy%0A * of this software and associated documentation files (the %22Software%22), to deal%0A * in the Software without restriction, including without limitation the rights%0A * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell%0A * copies of the Software, and to permit persons to whom the Software is%0A * furnished to do so, subject to the following conditions:%0A *%0A * The above copyright notice and this permission notice shall be included%0A * in all copies or substantial portions of the Software.%0A *%0A * THE SOFTWARE IS PROVIDED %22AS IS%22, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR%0A * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,%0A * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT. IN NO EVENT SHALL THE%0A * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER%0A * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,%0A * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE%0A * SOFTWARE.%0A */%0Apackage org.cactoos.func;%0A%0Aimport org.cactoos.Func;%0Aimport org.cactoos.matchers.RunsInThreads;%0Aimport org.hamcrest.MatcherAssert;%0Aimport org.hamcrest.Matchers;%0Aimport org.junit.Test;%0A%0A/**%0A * Test case for %7B@link SolidBiFunc%7D.%0A *%0A * @author Roman Proshin (roman@proshin.org)%0A * @version $Id$%0A * @since 1.0%0A */%0Apublic class SolidBiFuncTest %7B%0A    @Test%0A    public void testThatFuncIsSynchronized() %7B%0A        final int threads = 100;%0A        final int%5B%5D shared = new int%5B%5D%7B0%7D;%0A        final SolidBiFunc%3CInteger, Integer, Boolean%3E testable =%0A            new SolidBiFunc%3C%3E(%0A                (first, second) -%3E %7B%0A                    shared%5B0%5D = shared%5B0%5D + 1;%0A                    return true;%0A                %7D%0A            );%0A        MatcherAssert.assertThat(%0A            func -%3E func.apply(true),%0A            new RunsInThreads%3C%3E(%0A                (Func%3CBoolean, Boolean%3E) input -%3E testable.apply(1, 1),%0A                threads%0A            )%0A        );%0A        MatcherAssert.assertThat(shared%5B0%5D, Matchers.is(1));%0A    %7D%0A%0A    @Test%0A    public void testThatFuncResultCacheIsLimited() throws Exception %7B%0A        final int%5B%5D executions = new int%5B%5D%7B0, 0%7D;%0A        final SolidBiFunc%3CInteger, Integer, Boolean%3E func =%0A            new SolidBiFunc%3C%3E(%0A                (index, second) -%3E %7B%0A                    executions%5Bindex%5D = executions%5Bindex%5D + 1;%0A                    return true;%0A                %7D,%0A                1%0A            );%0A        func.apply(0, 0);%0A        func.apply(1, 1);%0A        func.apply(1, 1);%0A        func.apply(0, 0);%0A        MatcherAssert.assertThat(executions%5B0%5D, Matchers.is(2));%0A        MatcherAssert.assertThat(executions%5B1%5D, Matchers.is(1));%0A    %7D%0A%7D%0A

Add test cases for all ctors of SolidBiFunc