MockDataProvider.Disclaimer
The general idea of mocking a JDBC connection with this jOOQ API is to provide quick workarounds, injection points, etc. using a very simple JDBC abstraction. It is NOT RECOMMENDED to emulate an entire database (including complex state transitions, transactions, locking, etc.) using this mock API. Once you have this requirement, please consider using an actual database instead for integration testing (e.g. using https://www.testcontainers.org), rather than implementing your test database inside of a MockDataProvider.
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public static final MockDataProvider | |
| public static final MockDataProvider | |
| public static final MockDataProvider | of(Result<?> result)
Create a new |
| public static final MockDataProvider | of(MockResult... result)
Create a new |
| public static final MockDataProvider | of(SQLException exception)
Create a new |
| pack-priv static final Result |
| Mock | back to summary |
|---|---|
| private Mock() No instances | |
| of | back to summary |
|---|---|
| public static final MockDataProvider of(int rows) Create a new | |
| of | back to summary |
|---|---|
| public static final MockDataProvider of(Record record) Create a new | |
| of | back to summary |
|---|---|
| public static final MockDataProvider of(Result<?> result) Create a new | |
| of | back to summary |
|---|---|
| public static final MockDataProvider of(MockResult... result) Create a new | |
| of | back to summary |
|---|---|
| public static final MockDataProvider of(SQLException exception) Create a new | |
| result | back to summary |
|---|---|
| pack-priv static final Result Wrap a record in a result. | |