check( true, r6, new NativeSQLQueryJoinReturn( "b", "c", "a", Collections.singletonMap( "key", "value" ), LockMode.NONE ) );
check( true, r7, new NativeSQLQueryJoinReturn( "b", "c", "a", null, LockMode.NONE ) );
}
public void testNativeSQLQueryCollectionReturn() {
NativeSQLQueryCollectionReturn r1 = new NativeSQLQueryCollectionReturn( "a", "b", "c", null, null);
NativeSQLQueryCollectionReturn r2 = new NativeSQLQueryCollectionReturn( "a", "c", "b", null, null);
NativeSQLQueryCollectionReturn r3NullMap = new NativeSQLQueryCollectionReturn( "b", "c", "a", null, null);
NativeSQLQueryCollectionReturn r3EmptyMap= new NativeSQLQueryCollectionReturn( "b", "c", "a", new HashMap(), null);
NativeSQLQueryCollectionReturn r4 = new NativeSQLQueryCollectionReturn( "b", "c", "a", Collections.singletonMap( "key", "value" ), null);
NativeSQLQueryCollectionReturn r5 = new NativeSQLQueryCollectionReturn( "b", "c", "a", Collections.singletonMap( "otherkey", "othervalue" ), null);
NativeSQLQueryCollectionReturn r6 = new NativeSQLQueryCollectionReturn( "b", "c", "a", Collections.singletonMap( "key", "value" ), LockMode.NONE );
NativeSQLQueryCollectionReturn r7 = new NativeSQLQueryCollectionReturn( "b", "c", "a", null, LockMode.NONE );
check( false, r1, r2 );
check( false, r1, r3NullMap );
check( false, r1, r3EmptyMap );
check( false, r1, r4 );
check( false, r1, r5 );
check( false, r1, r6 );
check( false, r1, r7 );
check( false, r2, r3NullMap );
check( false, r2, r3EmptyMap );
check( false, r2, r4 );
check( false, r2, r5 );
check( false, r2, r6 );
check( false, r2, r7 );
check( true, r3NullMap, r3EmptyMap );
check( false, r3NullMap, r4 );
check( false, r3NullMap, r5 );
check( false, r3NullMap, r6 );
check( false, r3NullMap, r7 );
check( false, r3EmptyMap, r4 );
check( false, r3EmptyMap, r5 );
check( false, r3EmptyMap, r6 );
check( false, r3EmptyMap, r7 );
check( false, r4, r5 );
check( false, r4, r6 );
check( false, r4, r7 );
check( false, r5, r6 );
check( false, r5, r7 );
check( false, r6, r7 );
check( true, r1, new NativeSQLQueryCollectionReturn( "a", "b", "c", null, null) );
check( true, r2, new NativeSQLQueryCollectionReturn( "a", "c", "b", null, null) );
check( true, r3NullMap, new NativeSQLQueryCollectionReturn( "b", "c", "a", null, null) );
check( true, r3EmptyMap, new NativeSQLQueryCollectionReturn( "b", "c", "a", new HashMap(), null) );
check( true, r4, new NativeSQLQueryCollectionReturn( "b", "c", "a", Collections.singletonMap( "key", "value" ), null) );
check( true, r5, new NativeSQLQueryCollectionReturn( "b", "c", "a", Collections.singletonMap( "otherkey", "othervalue" ), null) );
check( true, r6, new NativeSQLQueryCollectionReturn( "b", "c", "a", Collections.singletonMap( "key", "value" ), LockMode.NONE ) );
check( true, r7, new NativeSQLQueryCollectionReturn( "b", "c", "a", null, LockMode.NONE ) );
}