Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: cherry-pick dependabot updates from master #6995

Merged
merged 24 commits into from
Jan 23, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
0803d03
build(deps): bump semver from 5.7.1 to 5.7.2 (#6756)
dependabot[bot] Jul 11, 2023
9bae2a8
build(deps): bump word-wrap from 1.2.3 to 1.2.4 (#6768)
dependabot[bot] Jul 19, 2023
0de6585
build(deps): bump @adobe/css-tools from 4.0.1 to 4.3.1 (#6795)
dependabot[bot] Sep 5, 2023
06d21b2
build(deps): bump postcss from 8.4.19 to 8.4.31 (#6815)
dependabot[bot] Oct 23, 2023
b836a36
build(deps): bump @babel/traverse from 7.16.3 to 7.23.2 (#6820)
dependabot[bot] Oct 17, 2023
32594ae
build(deps): bump crypto-js from 4.1.1 to 4.2.0 (#6825)
dependabot[bot] Oct 26, 2023
c68b254
build(deps): bump @adobe/css-tools from 4.3.1 to 4.3.2 (#6843)
dependabot[bot] Dec 1, 2023
ea53910
build(deps): bump follow-redirects from 1.14.8 to 1.15.4 (#6849)
dependabot[bot] Jan 10, 2024
827ddd9
build(deps): bump webpack-dev-middleware from 5.3.3 to 5.3.4 (#6878)
dependabot[bot] Mar 29, 2024
3df5b1f
build(deps): bump express from 4.18.2 to 4.19.2 (#6880)
dependabot[bot] Mar 29, 2024
32df2a2
build(deps): bump braces from 3.0.2 to 3.0.3 (#6895)
dependabot[bot] Jun 27, 2024
12e44d2
build(deps): bump ws from 6.2.2 to 6.2.3 (#6897)
dependabot[bot] Jun 27, 2024
21db5aa
chore(deps): Pin auth0 superagent version (#6903)
abshierjoel Jul 30, 2024
a5ba45d
build(deps): bump micromatch from 4.0.5 to 4.0.8 (#6937)
dependabot[bot] Sep 13, 2024
344da58
build(deps): bump express from 4.19.2 to 4.21.0 (#6949)
dependabot[bot] Sep 13, 2024
c839836
build(deps): bump dompurify from 2.3.4 to 2.5.6 (#6950)
dependabot[bot] Sep 19, 2024
af328ab
chore: update yarn.lock for oats and influxdb-templates (yarn install)
jdstrand Jan 23, 2025
30745da
build(deps): bump http-proxy-middleware from 2.0.6 to 2.0.7 (#6966)
dependabot[bot] Oct 25, 2024
14b428c
build(deps): bump nanoid from 3.2.0 to 3.3.8 (#6986)
dependabot[bot] Dec 17, 2024
e901635
fix: do not force focus on uses of monacotype support cmd (#6992)
wdoconnell Jan 2, 2025
2c739dd
chore: bump CI permitted retry, disable two flaky tests (#6919)
wdoconnell Jul 30, 2024
2a068b0
fix: correct tests to be handled by faster ci runner (#6911)
wdoconnell Jul 25, 2024
4a2a771
chore: add delay to tasks-searching test (#6913)
wdoconnell Jul 26, 2024
7eb16e2
fix: flake in scriptquerybuilder, tasks e2es (#6917)
wdoconnell Jul 29, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cypress.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"retries": {
"runMode": 2,
"runMode": 3,
"openMode": 0
},
"numTestsKeptInMemory": 25,
Expand Down
203 changes: 115 additions & 88 deletions cypress/e2e/shared/explorer.queries.graphs.test.ts
Original file line number Diff line number Diff line change
@@ -1,117 +1,135 @@
import {Organization} from '../../../src/types'

const featureFlags = {
showOldDataExplorerInNewIOx: true,
showTasksInNewIOx: true,
showVariablesInNewIOx: true,
schemaComposition: true, // Double check that the new schemaComposition flag does not interfere.
}

const DEFAULT_DELAY_MS = 1000

describe('writing queries and making graphs using Data Explorer', () => {
let route: string

beforeEach(() => {
cy.flush().then(() =>
cy.signin().then(() =>
cy
.setFeatureFlags({
showOldDataExplorerInNewIOx: true,
showTasksInNewIOx: true,
showVariablesInNewIOx: true,
schemaComposition: true, // Double check that the new schemaComposition flag does not interfere.
})
.then(() => {
// cy.wait($time) is necessary to consistently ensure sufficient time for the feature flag override.
// The flag reset happens via redux, (it's not a network request), so we can't cy.wait($intercepted_route).
cy.wait(1200)
cy.get('@org').then(({id}: Organization) => {
cy.createMapVariable(id)
cy.fixture('routes').then(({orgs, explorer}) => {
route = `${orgs}/${id}${explorer}`
cy.visit(route)
cy.getByTestID('tree-nav').should('be.visible')
cy.switchToDataExplorer('old')
})
cy.setFeatureFlags(featureFlags).then(() => {
// cy.wait($time) is necessary to consistently ensure sufficient time for the feature flag override.
// The flag reset happens via redux, (it's not a network request), so we can't cy.wait($intercepted_route).
cy.wait(1200)
cy.get('@org').then(({id}: Organization) => {
cy.createMapVariable(id)
cy.fixture('routes').then(({orgs, explorer}) => {
route = `${orgs}/${id}${explorer}`
cy.visit(route)
cy.getByTestID('tree-nav').should('be.visible')
cy.switchToDataExplorer('old')
})
})
})
)
)
})

describe('numeric input in graphs', () => {
describe('numeric input using custom bin sizes in Histograms', () => {
beforeEach(() => {
cy.getByTestID('view-type--dropdown').click()
cy.getByTestID(`view-type--histogram`).click()
cy.getByTestID('cog-cell--button').click()
cy.getByTestID('view-type--dropdown').click().wait(DEFAULT_DELAY_MS)
cy.getByTestID(`view-type--histogram`).click().wait(DEFAULT_DELAY_MS)
cy.getByTestID('cog-cell--button').click().wait(DEFAULT_DELAY_MS)
})

it('should put input field in error status and stay in error status when input is invalid or empty', () => {
cy.get('.view-options').within(() => {
cy.getByTestID('auto-input').within(() => {
cy.getByTestID('input-field').clear()
cy.getByTestID('auto-input--custom').should(
'have.class',
'cf-select-group--option__active'
)
cy.getByTestID('input-field--error').should('have.length', 1)
cy.getByTestID('input-field').type('adfuiopbvmc')
cy.getByTestID('input-field--error').should('have.length', 1)
cy.get('.view-options')
.first()
.within(() => {
cy.getByTestID('auto-input')
.first()
.within(() => {
cy.getByTestID('input-field').clear()
cy.getByTestID('auto-input--custom').should(
'have.class',
'cf-select-group--option__active'
)
cy.getByTestID('input-field--error').should('have.length', 1)
cy.getByTestID('input-field').type('adfuiopbvmc')
cy.getByTestID('input-field--error').should('have.length', 1)
})
})
})
})

it('should not have the input field in error status when input becomes valid', () => {
cy.get('.view-options').within(() => {
cy.getByTestID('auto-input').within(() => {
cy.getByTestID('input-field').clear().type('3')
cy.getByTestID('input-field--error').should('have.length', 0)
cy.get('.view-options')
.first()
.within(() => {
cy.getByTestID('auto-input')
.first()
.within(() => {
cy.getByTestID('input-field').clear().type('3')
cy.getByTestID('input-field--error').should('have.length', 0)
})
})
})
})
})

describe('numeric input validation when changing bin sizes in Heat Maps', () => {
beforeEach(() => {
cy.getByTestID('view-type--dropdown').click()
cy.getByTestID(`view-type--heatmap`).click()
cy.getByTestID('cog-cell--button').click()
cy.getByTestID('view-type--dropdown').click().wait(DEFAULT_DELAY_MS)
cy.getByTestID(`view-type--heatmap`).click().wait(DEFAULT_DELAY_MS)
cy.getByTestID('cog-cell--button').click().wait(DEFAULT_DELAY_MS)
})

it('should put input field in error status and stay in error status when input is invalid or empty', () => {
cy.get('.view-options').within(() => {
cy.getByTestID('grid--column').within(() => {
cy.getByTestID('bin-size-input')
.clear()
.getByTestID('bin-size-input--error')
.should('have.length', 1)
cy.getByTestID('bin-size-input')
.type('{backspace}')
.getByTestID('bin-size-input--error')
.should('have.length', 1)
cy.getByTestID('bin-size-input')
.type('4')
.getByTestID('bin-size-input--error')
.should('have.length', 1)
cy.getByTestID('bin-size-input')
.type('{backspace}abcdefg')
.getByTestID('bin-size-input--error')
.should('have.length', 1)
cy.get('.view-options')
.first()
.within(() => {
cy.getByTestID('grid--column')
.first()
.within(() => {
cy.getByTestID('bin-size-input')
.clear()
.getByTestID('bin-size-input--error')
.should('have.length', 1)
cy.getByTestID('bin-size-input')
.type('{backspace}')
.getByTestID('bin-size-input--error')
.should('have.length', 1)
cy.getByTestID('bin-size-input')
.type('4')
.getByTestID('bin-size-input--error')
.should('have.length', 1)
cy.getByTestID('bin-size-input')
.type('{backspace}abcdefg')
.getByTestID('bin-size-input--error')
.should('have.length', 1)
})
})
})
})

it('should not have input field in error status when "10" becomes valid input such as "5"', () => {
cy.get('.view-options').within(() => {
cy.getByTestID('grid--column').within(() => {
cy.getByTestID('bin-size-input')
.clear()
.type('5')
.getByTestID('bin-size-input--error')
.should('have.length', 0)
cy.get('.view-options')
.first()
.within(() => {
cy.getByTestID('grid--column')
.first()
.within(() => {
cy.getByTestID('bin-size-input')
.clear()
.type('5')
.getByTestID('bin-size-input--error')
.should('have.length', 0)
})
})
})
})
})

describe('numeric input validation when changing number of decimal places in Single Stat', () => {
beforeEach(() => {
cy.getByTestID('view-type--dropdown').click()
cy.getByTestID(`view-type--single-stat`).click()
cy.getByTestID('cog-cell--button').click()
cy.getByTestID('view-type--dropdown').click().wait(DEFAULT_DELAY_MS)
cy.getByTestID(`view-type--single-stat`).click().wait(DEFAULT_DELAY_MS)
cy.getByTestID('cog-cell--button').click().wait(DEFAULT_DELAY_MS)
})

it('should put input field in error status and stay in error status when input is invalid or empty', () => {
Expand Down Expand Up @@ -143,24 +161,31 @@ describe('writing queries and making graphs using Data Explorer', () => {
})

it('should not have input field in error status when "2" becomes valid input such as "11"', () => {
cy.get('.view-options').within(() => {
cy.getByTestID('auto-input--input').within(() => {
cy.getByTestID('input-field')
.click()
.type('{backspace}11')
.invoke('val')
.should('equal', '11')
.getByTestID('input-field--error')
.should('have.length', 0)
cy.get('.view-options')
.first()
.within(() => {
cy.getByTestID('auto-input--input')
.first()
.within(() => {
cy.getByTestID('input-field')
.click()
.type('{backspace}11')
.invoke('val')
.should('equal', '11')
.getByTestID('input-field--error')
.should('have.length', 0)
})
})
})
})
})
})

describe('raw script editing', () => {
beforeEach(() => {
cy.getByTestID('switch-to-script-editor').should('be.visible').click()
cy.getByTestID('switch-to-script-editor')
.should('be.visible')
.click()
.wait(1000)
})

it('shows the proper query button state', () => {
Expand All @@ -177,13 +202,15 @@ describe('writing queries and making graphs using Data Explorer', () => {
})

it('shows the empty state when the query returns no results', () => {
cy.getByTestID('time-machine--bottom').within(() => {
cy.getByTestID('flux-editor').should('be.visible')
.monacoType(`from(bucket: "defbuck")
cy.getByTestID('time-machine--bottom')
.first()
.within(() => {
cy.getByTestID('flux-editor').should('be.visible')
.monacoType(`from(bucket: "defbuck")
|> range(start: -10s)
|> filter(fn: (r) => r._measurement == "no exist")`)
cy.getByTestID('time-machine-submit-button').click()
})
cy.getByTestID('time-machine-submit-button').click()
})

cy.getByTestID('empty-graph--no-results').should('exist')
})
Expand Down Expand Up @@ -303,7 +330,7 @@ describe('writing queries and making graphs using Data Explorer', () => {
cy.get<Organization>('@org').then(({id, name}) => {
cy.createBucket(id, name, 'newBucket')
})
cy.reload()
cy.setFeatureFlags(featureFlags)
cy.get<string>('@defaultBucketListSelector').then(
(defaultBucketListSelector: string) => {
cy.getByTestID(defaultBucketListSelector).should('be.visible')
Expand Down
32 changes: 24 additions & 8 deletions cypress/e2e/shared/scriptQueryBuilder.results.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ const DELAY_FOR_LSP_SERVER_BOOTUP = 7000

const DELAY_FOR_FILE_DOWNLOAD = 5000

const DEFAULT_DELAY_MS = 2000

describe('Script Builder', () => {
const writeData: string[] = []
for (let i = 0; i < 30; i++) {
Expand Down Expand Up @@ -100,7 +102,8 @@ describe('Script Builder', () => {
})
})

it('will allow querying of different data ranges', () => {
// Temporarily disabled due to excess flake. Do not re-enable without rewriting this test.
it.skip('will allow querying of different data ranges', () => {
cy.log('Ensure LSP is online') // deflake
cy.wait(DELAY_FOR_LSP_SERVER_BOOTUP)

Expand All @@ -112,9 +115,18 @@ describe('Script Builder', () => {
cy.wait('@query -1h')

cy.log('query date range can be adjusted')
cy.getByTestID('timerange-dropdown--button').should('be.visible').click()
cy.getByTestID('dropdown-item-past15m').should('exist').click()
cy.getByTestID('time-machine-submit-button').should('exist').click()
cy.getByTestID('timerange-dropdown--button')
.should('be.visible')
.click()
.wait(DEFAULT_DELAY_MS)
cy.getByTestID('dropdown-item-past15m')
.should('exist')
.click()
.wait(DEFAULT_DELAY_MS)
cy.getByTestID('time-machine-submit-button')
.should('exist')
.click()
.wait(DEFAULT_DELAY_MS)
cy.wait('@query -15m')
})

Expand Down Expand Up @@ -145,7 +157,7 @@ describe('Script Builder', () => {
cy.getByTestID('time-machine-submit-button').should('exist')
cy.getByTestID('time-machine-submit-button').clickAttached()
cy.wait('@query -1h')
cy.wait(1000) // bit more time for csv parsing
cy.wait(DEFAULT_DELAY_MS) // bit more time for csv parsing

cy.log('table metadata displayed to user is correct')
if (truncated) {
Expand Down Expand Up @@ -197,12 +209,16 @@ describe('Script Builder', () => {
})

cy.log('turn off composition sync')
cy.getByTestID('editor-sync--toggle').click()
cy.getByTestID('editor-sync--toggle').click().wait(DEFAULT_DELAY_MS)
cy.getByTestID('editor-sync--toggle').should('not.have.class', 'active')
cy.log('select empty dataset')
cy.getByTestID('flux-editor').monacoType(`{selectall}{enter}
cy.getByTestID('flux-editor')
.monacoType(
`{selectall}{enter}
from(bucket: "defbuck3") |> range(start: v.timeRangeStart, stop: v.timeRangeStop)
`)
`
)
.wait(DEFAULT_DELAY_MS)
cy.getByTestID('flux-editor').contains('defbuck3')

runTest(0, 0, false)
Expand Down
10 changes: 6 additions & 4 deletions cypress/e2e/shared/simpleTable.test.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,18 @@
import {Organization} from '../../../src/types'
import {points} from '../../support/commands'

const featureFlags = {
showOldDataExplorerInNewIOx: true,
}

describe('simple table interactions', () => {
const simpleSmall = 'simple-small'
const simpleLarge = 'simple-large'
const simpleOverflow = 'simple-overflow'
beforeEach(() => {
cy.flush()
cy.signin()
cy.setFeatureFlags({
showOldDataExplorerInNewIOx: true,
}).then(() =>
cy.setFeatureFlags(featureFlags).then(() =>
cy.get('@org').then(({id: orgID}: Organization) => {
cy.fixture('routes').then(({orgs, explorer}) => {
cy.visit(`${orgs}/${orgID}${explorer}`)
Expand All @@ -23,7 +25,7 @@ describe('simple table interactions', () => {
cy.writeData(points(30), simpleSmall)
cy.createBucket(orgID, name, simpleOverflow)
cy.writeData(points(31), simpleOverflow)
cy.reload()
cy.setFeatureFlags(featureFlags)
})
)
})
Expand Down
Loading
Loading