Skip to content

Commit

Permalink
chore(step definition files): automatically resolve "../common/index.…
Browse files Browse the repository at this point in the history
…js" files
  • Loading branch information
Mohammer5 committed Apr 18, 2024
1 parent b5f4bb7 commit 30ab769
Show file tree
Hide file tree
Showing 84 changed files with 4 additions and 91 deletions.
4 changes: 2 additions & 2 deletions collections/forms/i18n/en.pot
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ msgstr ""
"Content-Type: text/plain; charset=utf-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
"POT-Creation-Date: 2024-03-21T09:13:47.826Z\n"
"PO-Revision-Date: 2024-03-21T09:13:47.826Z\n"
"POT-Creation-Date: 2024-04-18T04:00:14.144Z\n"
"PO-Revision-Date: 2024-04-18T04:00:14.144Z\n"

msgid "Upload file"
msgstr "Upload file"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('an unchecked Checkbox without value is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('an unchecked Checkbox with a value is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a multi-file IputField is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { When, Then } from '@badeball/cypress-cucumber-preprocessor'

When('a file with the wrong file type is provided', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('the MultiSelect has two options', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { When, Then } from '@badeball/cypress-cucumber-preprocessor'
import { hasValueMessage } from '../../../validators/hasValue.js'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('there are three options', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { When, Then } from '@badeball/cypress-cucumber-preprocessor'
import { hasValueMessage } from '../../../validators/hasValue.js'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('the SingleSelect has one option', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { When, Then } from '@badeball/cypress-cucumber-preprocessor'
import { hasValueMessage } from '../../../validators/hasValue.js'

Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('an unchecked Switch without value is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('an unchecked Switch with a value is rendered', () => {
Expand Down
1 change: 0 additions & 1 deletion components/alert/src/alert-bar/features/hide/index.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'
require('../common/index.js')

Given('a permanent AlertBar with hidden and onHidden is rendered', () => {
cy.visitStory('AlertBar', 'Hidden prop')
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a DropdownButton with onClick handler is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a disabled DropdownButton with onClick handler is rendered', () => {
cy.visitStory('DropdownButton', 'Disabled with onClick')
})

When('the DropdownButton is clicked', () => {
cy.get('[data-test="dhis2-uicore-dropdownbutton"] button').click({
force: true,
})
})

Then('the onClick handler is not called', () => {
cy.window().should((win) => {
expect(win.onClick).not.to.be.called
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a default DropdownButton is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SplitButton is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SplitButton with onClick hander is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('the list contains the file duplicate.md', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('the files are displayed in a list', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { When, Then } from '@badeball/cypress-cucumber-preprocessor'

When('the remove handle behind a file is clicked', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a FileInput with multiple and onChange handler is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a FileInput with onChange handler is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import {
Then,
When,
} from '@badeball/cypress-cucumber-preprocessor'
require('../common/index.js')

// see https://github.com/cypress-io/cypress/issues/17723#issuecomment-1457064322
const goOffline = () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('the HeaderBar dos not display the app menu', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then, When } from '@badeball/cypress-cucumber-preprocessor'

Given(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
require('../common/index.js')

// all step definitions are shared with other scenarios
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { When, Then } from '@badeball/cypress-cucumber-preprocessor'

When('the user clicks on the profile icons', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { When } from '@badeball/cypress-cucumber-preprocessor'

When('the user clicks outside of the menu', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('contains a link to edit the profile', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('contains a link to the user account', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('contains a link to the About DHIS2 page', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('contains a link to the help page', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('contains a link to the settings', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('contains the user name', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('the HeaderBar contains a link to the interpretations', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('there are 0 unread interpretations', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('the HeaderBar contains a link to the messages', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then, Given } from '@badeball/cypress-cucumber-preprocessor'

Given('there are 0 unread messages', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Then } from '@badeball/cypress-cucumber-preprocessor'

Then('the messages link contains an icon with a number greater than 0', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { Given } from '@badeball/cypress-cucumber-preprocessor'
require('../common/index.js')

Given(/the search contains a (.*)/, (character) => {
cy.get('[data-test="headerbar-apps-icon"]').click()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with onBlur handler is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with onFocus handler is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with initial focus is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with options and a loading flag is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with more than ten options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with a placeholder and no selection is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with a prefix and no selection is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with invalid options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a disabled MultiSelect with options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('an empty MultiSelect is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a filterable MultiSelect with options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with hidden sibling elements', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then, When } from '@badeball/cypress-cucumber-preprocessor'

Given(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a MultiSelect with options and a selection is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with onBlur handler is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with onFocus handler is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with initial focus is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with options and a loading flag is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with more than ten options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with a placeholder and no selection is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with a prefix and no selection is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with invalid options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given(
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a disabled SingleSelect with options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('an empty SingleSelect is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When, Then } from '@badeball/cypress-cucumber-preprocessor'

Given('a filterable SingleSelect with options is rendered', () => {
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
require('../common/index.js')
import { Given, When } from '@badeball/cypress-cucumber-preprocessor'

Given('a SingleSelect with options is rendered', () => {
Expand Down
Loading

0 comments on commit 30ab769

Please sign in to comment.