I have a better idea. Why don't I provide a test for it?
Would be great :).
I just can't figure how to make a patch so here it is. Just add it to GlorpDescriptorValidationTest class.
testValidateMultipleMappingsError
| descriptor table mapping1 mapping2 system field1 field2 |
system := DynamicDescriptorSystem new.
descriptor := system addEmptyDescriptorFor: GlorpCustomer.
table := DatabaseTable named: 'Table1'.
field1 := table createFieldNamed: 'one' type: OraclePlatform new integer.
field2 := table createFieldNamed: 'two' type: OraclePlatform new integer.
descriptor addTable: table.
mapping1 := descriptor newMapping: DirectMapping.
mapping1 from: #id to: field1.
mapping2 := descriptor newMapping: DirectMapping.
mapping2 from: #id to: field2.
self should: [descriptor validate] raise: MultipleMappingsForInstanceVariable