springtestdbunit / spring-test-dbunit

Integration between the Spring testing framework and DBUnit
http://springtestdbunit.github.com/spring-test-dbunit/
Apache License 2.0
476 stars 238 forks source link

Add support for additional info of columns #137

Open raderio opened 7 years ago

raderio commented 7 years ago

For example if a column has a type different from standard(string, number, ...) we must be able to add that specific info.

For example for this issue solution could be:

CREATE TYPE PRODUCT AS ENUM ('phone', 'laptop', 'mouse');

CREATE TABLE products (
    id BIGSERIAL NOT NULL PRIMARY KEY,
    title VARCHAR(20) NOT NULL,
    type PRODUCT NOT NULL
);
<dataset>
    <products id="1" title="Pixel">
        <column name="type" type="PRODUCT" value="laptop" />
    </products>
</dataset>
raderio commented 6 years ago

Other syntax could be

<dataset>
    <products id="1" title="Pixel" type:Product="laptop" />
</dataset>
raderio commented 6 years ago

https://sourceforge.net/p/dbunit/feature-requests/204/