package sqlancer;

import static org.junit.jupiter.api.Assertions.assertEquals;

import org.junit.jupiter.api.Test;

public class TestMain {

    @Test
    public void testSQLite() {
        // do not check the result, since we still find bugs in the SQLite3 version included in the JDBC driver
        Main.executeMain(new String[] { "--timeout-seconds", "30", "sqlite3", "--oracle", "NoREC" });
    }

    @Test
    public void testDuckDB() {
        assertEquals(0, Main.executeMain(new String[] { "--timeout-seconds", "30", "duckdb", "--oracle", "NoREC" }));
    }

}

@@ -135,16 +135,119 @@
 Main %7B%0A%0A
+    private static final String NUM_QUERIES = %221000%22;%0A    private static final String SECONDS = %2230%22;%0A%0A
     @Tes
@@ -456,24 +456,73 @@
 s%22, 
-%2230%22, %22sqlite3%22,
+SECONDS, %22--num_queries%22, NUM_QUERIES, %22sqlite3%22,%0A               
  %22--
@@ -671,42 +671,271 @@
 s%22, 
-%2230%22, %22duckdb%22, %22--oracle%22, %22NoREC
+SECONDS, %22--num_queries%22, NUM_QUERIES,%0A                %22duckdb%22, %22--oracle%22, %22NoREC%22 %7D));%0A        assertEquals(0, Main.executeMain(new String%5B%5D %7B %22--timeout-seconds%22, SECONDS, %22--num_queries%22, NUM_QUERIES,%0A                %22duckdb%22, %22--oracle%22, %22QUERY_PARTITIONING
 %22 %7D)

Test the NoREC and TLP oracles of DuckDB