From f9eb35fb29bceefcee1c6b0fd3defe9f23a1ed52 Mon Sep 17 00:00:00 2001 From: Frederic Stahel Date: Thu, 12 Dec 2024 14:22:51 +0100 Subject: [PATCH] Fix seed --- src/api/BdmsContextExtensions.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/api/BdmsContextExtensions.cs b/src/api/BdmsContextExtensions.cs index 92680ff2a..5942c5720 100644 --- a/src/api/BdmsContextExtensions.cs +++ b/src/api/BdmsContextExtensions.cs @@ -187,7 +187,6 @@ public static void SeedData(this BdmsContext context) .RuleFor(o => o.ReferenceElevationType, _ => default!) .RuleFor(o => o.BoreholeCodelists, _ => new Collection()) .RuleFor(o => o.Codelists, _ => new Collection()) - .RuleFor(o => o.Observations, _ => new Collection()) .RuleFor(o => o.Geometry, f => { var point = new Point(f.Random.Int(2477750, 2830750), f.Random.Int(1066750, 1310750)); @@ -199,6 +198,7 @@ public static void SeedData(this BdmsContext context) .RuleFor(o => o.PrecisionLocationY, f => f.PickRandom(Enumerable.Range(0, 10))) .RuleFor(o => o.PrecisionLocationXLV03, f => f.PickRandom(Enumerable.Range(0, 10))) .RuleFor(o => o.PrecisionLocationYLV03, f => f.PickRandom(Enumerable.Range(0, 10))) + .RuleFor(o => o.Observations, _ => new Collection()) .FinishWith((f, o) => { o.AlternateName = o.OriginalName; }); Borehole SeededBoreholes(int seed) => fakeBoreholes.UseSeed(seed).Generate();