### Question:
Tuple2 implements Tuple { public static <L, R> Tuple2<L, R> of(L l, R r) { return new Tuple2<>(l, r); } protected  Tuple2(L left, R right); static Tuple2<L, R> of(L l, R r); L getItem1(); R getItem2(); Tuple2<T, R> mapItem1(Function<L, T> mapper); Tuple2<L, T> mapItem2(Function<R, T> mapper); @Override Object nth(int index); @Override List<Object> asList(); @Override boolean equals(Object o); @Override int hashCode(); int size(); @Override String toString();  }### Answer:
@Test public void testThatNullIsAcceptedAsItem1() { Tuple2<Object, Integer> pair = Tuple2.of(null, 3); assertThat(pair).containsExactly(null, 3); }
@Test public void testThatNullIsAcceptedAsItem2() { Tuple2<Object, Integer> pair = Tuple2.of(3, null); assertThat(pair).containsExactly(3, null); }
@Test public void testEqualsWithStringAndInteger() { Tuple2<String, Integer> pair = Tuple2.of("a", 1); assertThat(pair).isEqualTo(pair); assertThat(pair).isNotEqualTo(null); assertThat(pair).isNotEqualTo("not a pair"); }
@Test public void testEqualsWithStringAndNull() { Tuple2<String, Integer> pair = Tuple2.of("a", null); assertThat(pair).isEqualTo(pair); assertThat(pair).isNotEqualTo(null); assertThat(pair).isNotEqualTo("not a pair"); assertThat(pair).isEqualTo(Tuple2.of("a", null)); assertThat(pair).isNotEqualTo(Tuple2.of(null, null)); }