@@ -16,6 +16,41 @@ internal sealed class MetaFakers
1616 . MakeDeterministic ( )
1717 . RuleFor ( supportTicket => supportTicket . Description , faker => faker . Lorem . Paragraph ( ) ) ) ;
1818
19+ private readonly Lazy < Faker < Dictionary < string , object > > > _lazyDocumentMetaFaker = new ( ( ) => new Faker < Dictionary < string , object > > ( )
20+ . MakeDeterministic ( )
21+ . CustomInstantiator ( faker => new Dictionary < string , object >
22+ {
23+ [ "requestId" ] = faker . Random . Guid ( ) . ToString ( )
24+ } ) ) ;
25+
26+ private readonly Lazy < Faker < Dictionary < string , object > > > _lazyResourceMetaFaker = new ( ( ) => new Faker < Dictionary < string , object > > ( )
27+ . MakeDeterministic ( )
28+ . CustomInstantiator ( faker => new Dictionary < string , object >
29+ {
30+ [ "editedBy" ] = faker . Internet . UserName ( ) ,
31+ [ "revision" ] = faker . Random . Int ( 1 , 10 )
32+ } ) ) ;
33+
34+ private readonly Lazy < Faker < Dictionary < string , object > > > _lazyRelationshipMetaFaker = new ( ( ) => new Faker < Dictionary < string , object > > ( )
35+ . MakeDeterministic ( )
36+ . CustomInstantiator ( faker => new Dictionary < string , object >
37+ {
38+ [ "source" ] = faker . PickRandom ( "ui" , "api" , "import" ) ,
39+ [ "confidence" ] = faker . Random . Double ( 0.1 , 1.0 )
40+ } ) ) ;
41+
42+ private readonly Lazy < Faker < Dictionary < string , object > > > _lazyRelationshipIdentifierMetaFaker = new ( ( ) => new Faker < Dictionary < string , object > > ( )
43+ . MakeDeterministic ( )
44+ . CustomInstantiator ( faker => new Dictionary < string , object >
45+ {
46+ [ "index" ] = faker . IndexFaker ,
47+ [ "optionalNote" ] = faker . Lorem . Word ( )
48+ } ) ) ;
49+
1950 public Faker < ProductFamily > ProductFamily => _lazyProductFamilyFaker . Value ;
2051 public Faker < SupportTicket > SupportTicket => _lazySupportTicketFaker . Value ;
52+ public Faker < Dictionary < string , object > > DocumentMeta => _lazyDocumentMetaFaker . Value ;
53+ public Faker < Dictionary < string , object > > ResourceMeta => _lazyResourceMetaFaker . Value ;
54+ public Faker < Dictionary < string , object > > RelationshipMeta => _lazyRelationshipMetaFaker . Value ;
55+ public Faker < Dictionary < string , object > > RelationshipIdentifierMeta => _lazyRelationshipIdentifierMetaFaker . Value ;
2156}
0 commit comments