ci: trigga på master + formatfix inför Gitea Actions
CI / Typecheck, test & build (push) Failing after 2s
CI / Typecheck, test & build (push) Failing after 2s
This commit is contained in:
@@ -98,7 +98,10 @@ describe("computeTrust", () => {
|
||||
|
||||
describe("householdTrustScore", () => {
|
||||
it("returns 100 / up_to_date for empty inventory", () => {
|
||||
const result = householdTrustScore({ items: [], correctionCount30d: 0, transactionCount30d: 0 }, PINNED);
|
||||
const result = householdTrustScore(
|
||||
{ items: [], correctionCount30d: 0, transactionCount30d: 0 },
|
||||
PINNED,
|
||||
);
|
||||
expect(result.score).toBe(100);
|
||||
expect(result.status).toBe("up_to_date");
|
||||
});
|
||||
@@ -107,8 +110,20 @@ describe("householdTrustScore", () => {
|
||||
const result = householdTrustScore(
|
||||
{
|
||||
items: [
|
||||
{ confidence: 1, verifiedByUser: true, lastVerifiedAt: PINNED, quantity: 2, updatedAt: PINNED },
|
||||
{ confidence: 1, verifiedByUser: true, lastVerifiedAt: PINNED, quantity: 3, updatedAt: PINNED },
|
||||
{
|
||||
confidence: 1,
|
||||
verifiedByUser: true,
|
||||
lastVerifiedAt: PINNED,
|
||||
quantity: 2,
|
||||
updatedAt: PINNED,
|
||||
},
|
||||
{
|
||||
confidence: 1,
|
||||
verifiedByUser: true,
|
||||
lastVerifiedAt: PINNED,
|
||||
quantity: 3,
|
||||
updatedAt: PINNED,
|
||||
},
|
||||
],
|
||||
correctionCount30d: 0,
|
||||
transactionCount30d: 0,
|
||||
@@ -124,7 +139,13 @@ describe("householdTrustScore", () => {
|
||||
const result = householdTrustScore(
|
||||
{
|
||||
items: [
|
||||
{ confidence: 0.3, verifiedByUser: false, lastVerifiedAt: null, quantity: 0.1, updatedAt: old },
|
||||
{
|
||||
confidence: 0.3,
|
||||
verifiedByUser: false,
|
||||
lastVerifiedAt: null,
|
||||
quantity: 0.1,
|
||||
updatedAt: old,
|
||||
},
|
||||
],
|
||||
correctionCount30d: 5,
|
||||
transactionCount30d: 10,
|
||||
@@ -140,8 +161,20 @@ describe("householdTrustScore", () => {
|
||||
const result = householdTrustScore(
|
||||
{
|
||||
items: [
|
||||
{ confidence: 0.8, verifiedByUser: true, lastVerifiedAt: weekAgo, quantity: 1, updatedAt: weekAgo },
|
||||
{ confidence: 0.5, verifiedByUser: false, lastVerifiedAt: null, quantity: 1, updatedAt: weekAgo },
|
||||
{
|
||||
confidence: 0.8,
|
||||
verifiedByUser: true,
|
||||
lastVerifiedAt: weekAgo,
|
||||
quantity: 1,
|
||||
updatedAt: weekAgo,
|
||||
},
|
||||
{
|
||||
confidence: 0.5,
|
||||
verifiedByUser: false,
|
||||
lastVerifiedAt: null,
|
||||
quantity: 1,
|
||||
updatedAt: weekAgo,
|
||||
},
|
||||
],
|
||||
correctionCount30d: 1,
|
||||
transactionCount30d: 5,
|
||||
|
||||
Reference in New Issue
Block a user