Skip to content

Commit

Permalink
chore: use visualizations without this year period
Browse files Browse the repository at this point in the history
This is to avoid failing tests in the beginning of a new year when the
new data is not added to the test DB yet.
  • Loading branch information
edoardo committed Jan 3, 2025
1 parent f89ac7b commit 546b487
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions cypress/integration/interpretations.cy.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { VIS_TYPE_BAR } from '@dhis2/analytics'
import { VIS_TYPE_LINE } from '@dhis2/analytics'
import {
expectAOTitleToBeValue,
expectVisualizationToBeVisible,
Expand All @@ -9,8 +9,8 @@ import { goToStartPage } from '../elements/startScreen.js'
describe('Interpretations', () => {
it('opens the interpretations modal on a saved AO', () => {
const ao = {
name: 'ANC: 1 and 3 coverage Yearly',
type: VIS_TYPE_BAR,
name: 'ANC: 1-3 trend lines last 12 months',
type: VIS_TYPE_LINE,
}

// Open the saved AO
Expand Down
6 changes: 3 additions & 3 deletions cypress/integration/save.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ import {
selectIndicators,
selectDataElements,
clickDimensionModalUpdateButton,
deselectOrgUnitTreeItem,
selectOrgUnitTreeItem,
} from '../elements/dimensionModal/index.js'
import { openDimension } from '../elements/dimensionsPanel.js'
import {
Expand Down Expand Up @@ -185,7 +185,7 @@ describe('saving an AO', () => {
})

it('"save" a copied AO created by others works after editing', () => {
const TEST_VIS_BY_OTHERS_NAME = 'ANC: 1-3 dropout rate Yearly'
const TEST_VIS_BY_OTHERS_NAME = 'ANC: 1-3 trend lines last 12 months'
const TEST_VIS_BY_OTHERS_NAME_UPDATED = `${TEST_VIS_BY_OTHERS_NAME} - updated`

// navigates to the start page and opens an AO created by others
Expand All @@ -200,7 +200,7 @@ describe('saving an AO', () => {

// edits the AO
openDimension(DIMENSION_ID_ORGUNIT)
deselectOrgUnitTreeItem('Western Area')
selectOrgUnitTreeItem('Western Area')
clickDimensionModalUpdateButton()

// saves AO using "Save"
Expand Down
2 changes: 1 addition & 1 deletion cypress/utils/data.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export const visTypes = [

export const TEST_AOS = [
{
name: 'Commodities: Child health consumption districts this year',
name: 'ANC: ANC 3 coverage by districts last 12 months',
type: VIS_TYPE_COLUMN,
},
{
Expand Down

0 comments on commit 546b487

Please sign in to comment.