import org.junit.Test; import static org.junit.Assert.*; public class MainTest { @Test public void test_1() { assertEquals(2, Main.smallestSubarrayLength(new int[]{2, 3, 1, 2, 4, 3}, 7)); } @Test public void test_2() { assertEquals(0, Main.smallestSubarrayLength(new int[]{1, 2, 3, 4}, 20)); } @Test public void test_3() { assertEquals(2, Main.smallestSubarrayLength(new int[]{1, 2, 3, 4, 5}, 9)); } }