GRO-1955: hotfix seed.ts broken uc reference in random pet batch (#112)
This commit was merged in pull request #112.
This commit is contained in:
@@ -966,14 +966,6 @@ async function seed() {
|
|||||||
temperamentScore: randInt(1, 5),
|
temperamentScore: randInt(1, 5),
|
||||||
temperamentFlags: pickN(temperamentFlagPool, randInt(1, 3)),
|
temperamentFlags: pickN(temperamentFlagPool, randInt(1, 3)),
|
||||||
medicalAlerts: (() => {
|
medicalAlerts: (() => {
|
||||||
// Deterministic alerts for UAT AC pets
|
|
||||||
if (uc.petName === "TestCooper") {
|
|
||||||
return pickN(medicalAlertPool.filter((a) => a.type === "behavioral"), 1).map((a) => ({ ...a, id: uuid() }));
|
|
||||||
}
|
|
||||||
if (uc.petName === "TestRocky") {
|
|
||||||
return pickN(medicalAlertPool.filter((a) => a.type === "skin"), 1).map((a) => ({ ...a, id: uuid() }));
|
|
||||||
}
|
|
||||||
// Other UAT pets: random
|
|
||||||
if (rand() < 0.3) {
|
if (rand() < 0.3) {
|
||||||
const count = rand() < 0.7 ? 1 : 2;
|
const count = rand() < 0.7 ? 1 : 2;
|
||||||
return pickN(medicalAlertPool, count).map((a) => ({ ...a, id: uuid() }));
|
return pickN(medicalAlertPool, count).map((a) => ({ ...a, id: uuid() }));
|
||||||
@@ -1101,14 +1093,6 @@ async function seed() {
|
|||||||
temperamentScore: randInt(1, 5),
|
temperamentScore: randInt(1, 5),
|
||||||
temperamentFlags: pickN(temperamentFlagPool, randInt(1, 3)),
|
temperamentFlags: pickN(temperamentFlagPool, randInt(1, 3)),
|
||||||
medicalAlerts: (() => {
|
medicalAlerts: (() => {
|
||||||
// Deterministic alerts for UAT AC pets
|
|
||||||
if (uc.petName === "TestCooper") {
|
|
||||||
return pickN(medicalAlertPool.filter((a) => a.type === "behavioral"), 1).map((a) => ({ ...a, id: uuid() }));
|
|
||||||
}
|
|
||||||
if (uc.petName === "TestRocky") {
|
|
||||||
return pickN(medicalAlertPool.filter((a) => a.type === "skin"), 1).map((a) => ({ ...a, id: uuid() }));
|
|
||||||
}
|
|
||||||
// Other UAT pets: random
|
|
||||||
if (rand() < 0.3) {
|
if (rand() < 0.3) {
|
||||||
const count = rand() < 0.7 ? 1 : 2;
|
const count = rand() < 0.7 ? 1 : 2;
|
||||||
return pickN(medicalAlertPool, count).map((a) => ({ ...a, id: uuid() }));
|
return pickN(medicalAlertPool, count).map((a) => ({ ...a, id: uuid() }));
|
||||||
|
|||||||
Reference in New Issue
Block a user