Skip to content

Commit

Permalink
Add type Smallint as SQLValue
Browse files Browse the repository at this point in the history
Close #164
  • Loading branch information
Ilia Rogozhin committed Nov 21, 2018
1 parent 7c22d87 commit e5d9a7e
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 92 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
package com.github.smallcreep.cucumber.seeds.sqlvalue;

/**
* Integer sql value.
* Number sql value.
* @since 0.2.1
*/
public final class SqlInteger extends SqlValueAsIs {
public final class SqlNumber extends SqlValueAsIs {

}
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,8 @@
import com.github.smallcreep.cucumber.seeds.SqlValue;
import com.github.smallcreep.cucumber.seeds.Table;
import com.github.smallcreep.cucumber.seeds.sqlvalue.Bytea;
import com.github.smallcreep.cucumber.seeds.sqlvalue.Serial;
import com.github.smallcreep.cucumber.seeds.sqlvalue.SqlBoolean;
import com.github.smallcreep.cucumber.seeds.sqlvalue.SqlInteger;
import com.github.smallcreep.cucumber.seeds.sqlvalue.SqlNumber;
import com.github.smallcreep.cucumber.seeds.sqlvalue.Text;
import com.github.smallcreep.cucumber.seeds.sqlvalue.Varchar;
import com.jcabi.xml.XML;
Expand Down Expand Up @@ -79,7 +78,7 @@ public TableXml(final Table table, final XML schema) {
),
new MapEntry<>(
"Serial",
new Serial()
new SqlNumber()
),
new MapEntry<>(
"Text",
Expand All @@ -91,7 +90,11 @@ public TableXml(final Table table, final XML schema) {
),
new MapEntry<>(
"Integer",
new SqlInteger()
new SqlNumber()
),
new MapEntry<>(
"Smallint",
new SqlNumber()
),
new MapEntry<>(
"Boolean",
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -29,20 +29,20 @@
import org.junit.Test;

/**
* Test Case for {@link SqlInteger}.
* Test Case for {@link SqlNumber}.
* @since 0.2.1
*/
public final class SqlIntegerTest {
public final class SqlNumberTest {

/**
* SqlInteger return input without modification.
* SqlNumber return input without modification.
* @throws Exception if fails
*/
@Test
public void returnInputWithoutModification() throws Exception {
final String input = "returnInputWithoutModification";
MatcherAssert.assertThat(
new SqlInteger().apply(input),
new SqlNumber().apply(input),
Matchers.equalTo(input)
);
}
Expand Down

0 comments on commit e5d9a7e

Please sign in to comment.