{"record":{"id":"44f5695b6e5fafd2","repo":"remix-run/remix","slug":"expected-promise-to-reject-but-it-resolved-with","errorCode":null,"errorMessage":"expected promise to reject, but it resolved with: ${stringify(result.value)}","messagePattern":"expected promise to reject, but it resolved with: (.+?)","errorType":"exception","errorClass":"AssertionError","httpStatus":null,"severity":"error","filePath":"packages/assert/src/lib/expect.ts","lineNumber":478,"sourceCode":"    }\n  }\n\n  function buildMatcher(matcher: keyof Matchers) {\n    return async (...args: unknown[]) => {\n      let result = await settle()\n      if (mode === 'resolves') {\n        if (!result.resolved) {\n          throw new AssertionError({\n            message: `expected promise to resolve, but it rejected with: ${stringify(result.error)}`,\n            actual: result.error,\n            operator: `resolves.${matcher}`,\n          })\n        }\n        let m = createMatchers(result.value, negated) as any\n        m[matcher](...args)\n      } else {\n        if (result.resolved) {\n          throw new AssertionError({\n            message: `expected promise to reject, but it resolved with: ${stringify(result.value)}`,\n            actual: result.value,\n            operator: `rejects.${matcher}`,\n          })\n        }\n        // For rejects.toThrow we check the error against the expected matcher.\n        if (matcher === 'toThrow') {\n          let pass = checkErrorMatch(result.error, args[0])\n          if (negated ? pass : !pass) {\n            throw new AssertionError({\n              message:\n                (negated ? 'expected not ' : 'expected ') +\n                `error to be ${describeExpectedError(args[0])}, got ${stringify(result.error)}`,\n              actual: result.error,\n              expected: args[0],\n              operator: `rejects.toThrow`,\n            })\n          }","sourceCodeStart":460,"sourceCodeEnd":496,"githubUrl":"https://github.com/remix-run/remix/blob/9696913134be3a4423513d2775f7b31d6917c049/packages/assert/src/lib/expect.ts#L460-L496","documentation":"`remix db seed` requires a seed script path from `db.seed` in `remix.json` or the `--seed` flag. This is the plan-time check in `resolveDatabaseCommandPlan`; without a seed path the plan cannot be built because there's nothing to execute.","triggerScenarios":"Running `remix db seed` when both `config.db.seed` is absent from remix.json and no `--seed` flag was passed.","commonSituations":"Fresh apps with no seed script configured yet; config has migrations but omits seed; assuming a default `seed.ts` is auto-detected.","solutions":["Pass `--seed ./db/seed.ts` on the command line","Add `\"seed\": \"./db/seed.ts\"` to the `db` section of remix.json","Create the seed script first if it doesn't exist yet"],"exampleFix":"# before\nremix db seed\n# after\nremix db seed --seed ./db/seed.ts","handlingStrategy":"validation","validationCode":"let config = JSON.parse(fs.readFileSync('remix.json','utf8'));\nlet seed = config?.db?.seed ?? './db/seed.ts';\nrun(['remix','db','seed','--seed',seed])","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Set db.seed in remix.json for repeatable seeding","Create the seed script before referencing it","Pass --seed when trying things out"],"tags":["cli","database","seed","config"],"backgroundTag":"required-option-missing","analyzedSha":"9696913134be3a4423513d2775f7b31d6917c049","analyzedAt":"2026-08-27T19:55:01.024Z","schemaVersion":2},"datasetVersion":"2026-08-28T00:17:15.603Z"}