Examples of DriverScript


Examples of com.asakusafw.windgate.core.DriverScript

     */
    @Test
    public void multiple_columns() {
        Mock mock = new Mock(String.class, "testing", StringSupport.class, "TESTING",
                "A", "B", "C");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        Map<String, String> conf = script.getConfiguration();
        assertThat(conf.size(), is(4));
        assertThat(conf.get(JdbcProcess.TABLE.key()), is("TESTING"));
        assertThat(conf.get(JdbcProcess.COLUMNS.key()), equalToIgnoringWhiteSpace("A, B, C"));
        assertThat(conf.get(JdbcProcess.JDBC_SUPPORT.key()), is(StringSupport.class.getName()));
        assertThat(conf.get(JdbcProcess.OPERATION.key()), is(not(nullValue())));
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Table not specified.
     */
    @Test(expected = IllegalStateException.class)
    public void no_tables() {
        Mock mock = new Mock(String.class, "testing", StringSupport.class, null, "VALUE");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Table is empty.
     */
    @Test(expected = IllegalStateException.class)
    public void empty_table() {
        Mock mock = new Mock(String.class, "testing", StringSupport.class, "", "VALUE");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Columns not specified.
     */
    @Test(expected = IllegalStateException.class)
    public void no_columns() {
        Mock mock = new Mock(String.class, "testing", StringSupport.class, "TESTING", (String[]) null);
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Columns are empty.
     */
    @Test(expected = IllegalStateException.class)
    public void empty_columns() {
        Mock mock = new Mock(String.class, "testing", StringSupport.class, "TESTING");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Contains empty column.
     */
    @Test(expected = IllegalStateException.class)
    public void has_empty_column() {
        Mock mock = new Mock(String.class, "testing", StringSupport.class, "TESTING", "");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Contains null column.
     */
    @Test(expected = IllegalStateException.class)
    public void has_null_column() {
        Mock mock = new Mock(String.class, "testing", StringSupport.class, "TESTING", "VALUE", null);
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * JDBC Support not specified.
     */
    @Test(expected = IllegalStateException.class)
    public void no_support() {
        Mock mock = new Mock(String.class, "testing", null, "TESTING", "VALUE");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Inconsistent JDBC support.
     */
    @Test(expected = IllegalStateException.class)
    public void invalid_type_support() {
        Mock mock = new Mock(String.class, "testing", VoidSupport.class, "TESTING", "VALUE");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here

Examples of com.asakusafw.windgate.core.DriverScript

     * Columns are not supported.
     */
    @Test(expected = IllegalStateException.class)
    public void invalid_columns() {
        Mock mock = new Mock(String.class, "testing", NullSupport.class, "TESTING", "VALUE");
        DriverScript script = mock.getDriverScript();
        assertThat(script.getResourceName(), is(Constants.JDBC_RESOURCE_NAME));
        script.getConfiguration();
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.