681 dashboard fetch data from all active resources #464
Annotations
10 errors and 1 warning
test/unit/middleware/overview.middleware.test.js > overview.middleware > prepareOverviewTemplateParams > should render the overview page:
test/unit/middleware/overview.middleware.test.js#L75
AssertionError: expected { organisation: { …(2) }, …(5) } to deeply equal { organisation: { …(2) }, …(5) }
- Expected
+ Received
Object {
"datasets": Object {
"other": ArrayContaining [
Object {
"dataset": "dataset2",
"endpoint": null,
"error": undefined,
"issue_count": 0,
"project": "open-digital-planning",
"status": "Needs fixing",
},
],
"statutory": ArrayContaining [
Object {
"dataset": "dataset1",
"endpoint": "https://example.com",
"error": undefined,
"issue_count": 0,
"project": "open-digital-planning",
"status": "Live",
},
Object {
"dataset": "dataset3",
"endpoint": "https://example.com",
"error": undefined,
"issue_count": 0,
"project": "open-digital-planning",
"status": "Error",
},
],
},
- "datasetsWithEndpoints": 2,
+ "datasetsWithEndpoints": 0,
"datasetsWithErrors": 1,
"datasetsWithIssues": 1,
"organisation": Object {
"name": "Example LPA",
"organisation": "LPA",
},
"totalDatasets": 3,
}
❯ test/unit/middleware/overview.middleware.test.js:75:34
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > aggregateOverviewData middleware > should set req.datasets to just the required datasets when input is empty:
test/unit/middleware/overview.middleware.test.js#L89
TypeError: aggregateOverviewData is not a function
❯ test/unit/middleware/overview.middleware.test.js:89:13
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > aggregateOverviewData middleware > should count issues correctly:
test/unit/middleware/overview.middleware.test.js#L105
TypeError: aggregateOverviewData is not a function
❯ test/unit/middleware/overview.middleware.test.js:105:13
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > aggregateOverviewData middleware > should ensure dataset issues get to the surface:
test/unit/middleware/overview.middleware.test.js#L125
TypeError: aggregateOverviewData is not a function
❯ test/unit/middleware/overview.middleware.test.js:125:13
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > aggregateOverviewData middleware > should handle multiple fields:
test/unit/middleware/overview.middleware.test.js#L139
TypeError: aggregateOverviewData is not a function
❯ test/unit/middleware/overview.middleware.test.js:139:13
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > aggregateOverviewData middleware > should't add a required dataset if it is already present:
test/unit/middleware/overview.middleware.test.js#L152
TypeError: aggregateOverviewData is not a function
❯ test/unit/middleware/overview.middleware.test.js:152:13
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > getOverview > should call render with the correct template and params:
test/unit/middleware/overview.middleware.test.js#L183
AssertionError: expected "spy" to be called 1 times, but got 0 times
❯ test/unit/middleware/overview.middleware.test.js:183:26
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > datasetSubmissionDeadlineCheck > sets dueNotice flag if they are in the notice period and they haven't submitted this year:
src/middleware/overview.middleware.js#L63
TypeError: Cannot read properties of undefined (reading '#<Object>')
❯ src/middleware/overview.middleware.js:63:18
❯ Module.datasetSubmissionDeadlineCheck src/middleware/overview.middleware.js:61:38
❯ test/unit/middleware/overview.middleware.test.js:213:13
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > datasetSubmissionDeadlineCheck > sets overdueNotice flag if they haven't submitted for last year:
src/middleware/overview.middleware.js#L63
TypeError: Cannot read properties of undefined (reading '#<Object>')
❯ src/middleware/overview.middleware.js:63:18
❯ Module.datasetSubmissionDeadlineCheck src/middleware/overview.middleware.js:61:38
❯ test/unit/middleware/overview.middleware.test.js:229:13
|
test/unit/middleware/overview.middleware.test.js > overview.middleware > datasetSubmissionDeadlineCheck > doesn't set any flag if they have submitted this year and we are in the notice period:
src/middleware/overview.middleware.js#L63
TypeError: Cannot read properties of undefined (reading '#<Object>')
❯ src/middleware/overview.middleware.js:63:18
❯ Module.datasetSubmissionDeadlineCheck src/middleware/overview.middleware.js:61:38
❯ test/unit/middleware/overview.middleware.test.js:245:13
|
test
ubuntu-latest pipelines will use ubuntu-24.04 soon. For more details, see https://github.com/actions/runner-images/issues/10636
|