File tree Expand file tree Collapse file tree 4 files changed +14
-12
lines changed Expand file tree Collapse file tree 4 files changed +14
-12
lines changed Original file line number Diff line number Diff line change @@ -92,7 +92,7 @@ public Glarch Glarch
92
92
private IDictionary < string , Ternary > _ternaryMap ;
93
93
//<set> mapping
94
94
private ISet < Ternary > _ternarySet ;
95
- private One _one ;
95
+ private One _oneToOne ;
96
96
97
97
public virtual IList < Simple > OneToMany
98
98
{
@@ -130,10 +130,10 @@ public virtual long Id
130
130
set { _id = value ; }
131
131
}
132
132
133
- public virtual One One
133
+ public virtual One OneToOne
134
134
{
135
- get => _one ;
136
- set => _one = value ;
135
+ get => _oneToOne ;
136
+ set => _oneToOne = value ;
137
137
}
138
138
139
139
public virtual IList < Contained > Bag
Original file line number Diff line number Diff line change 22
22
>
23
23
<generator class =" native" />
24
24
</id >
25
- <one-to-one name =" One " />
25
+ <one-to-one name =" OneToOne " />
26
26
<list
27
27
name=" OneToMany"
28
28
lazy=" true"
Original file line number Diff line number Diff line change @@ -383,9 +383,10 @@ public async Task CollectionQueryAsync()
383
383
l . Add ( null ) ;
384
384
l . Add ( s2 ) ;
385
385
c . ManyToMany = l ;
386
- c . One = new One { Value = "one" } ;
387
- await ( s . SaveAsync ( c . One ) ) ;
386
+ c . OneToOne = new One { Value = "one" } ;
387
+ await ( s . SaveAsync ( c . OneToOne ) ) ;
388
388
await ( s . SaveAsync ( c ) ) ;
389
+ await ( s . FlushAsync ( ) ) ;
389
390
390
391
Assert . AreEqual ( 1 ,
391
392
( await ( s . CreateQuery ( "select c from c in class ContainerX, s in class Simple where c.OneToMany[2] = s" ) . ListAsync
@@ -429,7 +430,7 @@ public async Task CollectionQueryAsync()
429
430
"select c from c in class ContainerX where c.ManyToMany[ c.OneToMany[0].Count ].Name = 's'" ) . ListAsync ( ) ) ) .
430
431
Count ) ;
431
432
432
- await ( s . DeleteAsync ( c . One ) ) ;
433
+ await ( s . DeleteAsync ( c . OneToOne ) ) ;
433
434
await ( s . DeleteAsync ( c ) ) ;
434
435
await ( s . DeleteAsync ( s1 ) ) ;
435
436
await ( s . DeleteAsync ( s2 ) ) ;
Original file line number Diff line number Diff line change @@ -372,15 +372,16 @@ public void CollectionQuery()
372
372
l . Add ( null ) ;
373
373
l . Add ( s2 ) ;
374
374
c . ManyToMany = l ;
375
- c . One = new One { Value = "one" } ;
376
- s . Save ( c . One ) ;
375
+ c . OneToOne = new One { Value = "one" } ;
376
+ s . Save ( c . OneToOne ) ;
377
377
s . Save ( c ) ;
378
+ s . Flush ( ) ;
378
379
379
380
Assert . AreEqual ( 1 ,
380
381
s . CreateQuery ( "select c from c in class ContainerX, s in class Simple where c.OneToMany[2] = s" ) . List
381
382
( ) . Count ) ;
382
383
Assert . AreEqual ( 1 ,
383
- s . CreateQuery ( "select c from c in class ContainerX, s in class Simple where c.OneToMany[2] = s and c.One != null" ) . List
384
+ s . CreateQuery ( "select c from c in class ContainerX, s in class Simple where c.OneToMany[2] = s and c.OneToOne != null" ) . List
384
385
( ) . Count ) ;
385
386
Assert . AreEqual ( 1 ,
386
387
s . CreateQuery ( "select c from c in class ContainerX, s in class Simple where c.ManyToMany[2] = s" ) .
@@ -418,7 +419,7 @@ public void CollectionQuery()
418
419
"select c from c in class ContainerX where c.ManyToMany[ c.OneToMany[0].Count ].Name = 's'" ) . List ( ) .
419
420
Count ) ;
420
421
421
- s . Delete ( c . One ) ;
422
+ s . Delete ( c . OneToOne ) ;
422
423
s . Delete ( c ) ;
423
424
s . Delete ( s1 ) ;
424
425
s . Delete ( s2 ) ;
You can’t perform that action at this time.
0 commit comments