Add full Markdown documentation set
This commit is contained in:
70
docs/test-driven-examples.md
Normal file
70
docs/test-driven-examples.md
Normal file
@@ -0,0 +1,70 @@
|
||||
# Test-Driven Examples
|
||||
|
||||
This page maps concrete examples to test files so behavior can be verified quickly.
|
||||
|
||||
## Dynamic Select and Aggregates
|
||||
|
||||
Source: `DynamORM.Tests/Select/DynamicAccessTests.cs`
|
||||
|
||||
- `Count/Min/Max/Avg/Sum/Scalar`
|
||||
- `First/Last/Single`
|
||||
- `IN`, `LIKE`, `BETWEEN`, comparison operators
|
||||
- ad-hoc column expressions and aliases
|
||||
|
||||
## Typed Access and Mapping
|
||||
|
||||
Source: `DynamORM.Tests/Select/TypedAccessTests.cs`
|
||||
|
||||
- `Query(type: typeof(T))`
|
||||
- `Execute<T>()`
|
||||
- projection with `MapEnumerable<T>()`
|
||||
- table mapping and strongly typed expressions
|
||||
|
||||
## SQL Parser and CommandText Expectations
|
||||
|
||||
Source: `DynamORM.Tests/Select/ParserTests.cs`
|
||||
|
||||
- `From` variants (`schema.table`, aliasing, string forms)
|
||||
- join expressions and join kind helpers
|
||||
- subquery embedding
|
||||
- `NoLock()` translation
|
||||
- deterministic SQL text generation checks
|
||||
|
||||
## Data Modification
|
||||
|
||||
Source: `DynamORM.Tests/Modify/DynamicModificationTests.cs`
|
||||
|
||||
- insert via named args, anonymous object, mapped class, plain class
|
||||
- update via key/object/where
|
||||
- delete via key/object/where
|
||||
|
||||
## Schema Variants
|
||||
|
||||
Sources:
|
||||
|
||||
- `DynamORM.Tests/Modify/DynamicTypeSchemaModificationTests.cs`
|
||||
- `DynamORM.Tests/Modify/DynamicNoSchemaModificationTests.cs`
|
||||
- `DynamORM.Tests/Select/DynamicTypeSchemaAccessTests.cs`
|
||||
- `DynamORM.Tests/Select/DynamicNoSchemaAccessTests.cs`
|
||||
|
||||
Use these to validate behavior with and without schema support.
|
||||
|
||||
## Resource and Pooling Semantics
|
||||
|
||||
Source: `DynamORM.Tests/Helpers/PoolingTests.cs`
|
||||
|
||||
- command invalidation after database disposal
|
||||
- transaction rollback behavior during disposal
|
||||
|
||||
## Validation
|
||||
|
||||
Source: `DynamORM.Tests/Helpers/Validation/ObjectValidationTest.cs`
|
||||
|
||||
- rule-based object validation with `RequiredAttribute`
|
||||
- array element-level validation
|
||||
|
||||
## Dynamic Parser (Helper Layer)
|
||||
|
||||
Source: `DynamORM.Tests/Helpers/Dynamic/DynamicParserTests.cs`
|
||||
|
||||
Covers lower-level parser behavior used by fluent lambda parsing.
|
||||
Reference in New Issue
Block a user