@enact/ui-test-utils 1.0.10 → 2.0.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/.travis.yml CHANGED
@@ -1,7 +1,7 @@
1
1
  dist: jammy
2
2
  language: node_js
3
3
  node_js:
4
- - node
4
+ - 21
5
5
  before_install:
6
6
  - sudo apt-get update
7
7
  - sudo apt-get install build-essential libcairo2-dev libpango1.0-dev libjpeg-dev libgif-dev librsvg2-dev
package/CHANGELOG.md CHANGED
@@ -1,5 +1,10 @@
1
1
  # Change Log
2
2
 
3
+ ## [2.0.0-alpha.1] (February 26, 2025)
4
+
5
+ * Updated `eslint` to v9 and adopted flat config.
6
+ * Added `--no-animation` option for screenshot test.
7
+
3
8
  ## [1.0.10] (October 31, 2024)
4
9
 
5
10
  * Updated dependencies.
package/README.md CHANGED
@@ -35,7 +35,7 @@ and must be configured as a `devDependency` of the UI library.
35
35
  }
36
36
  ```
37
37
 
38
- 6. Optionally configure different ESLint and git configuration rules using `.eslintrc.js` and
38
+ 6. Optionally configure different ESLint and git configuration rules using `eslint.config.js` and
39
39
  `.gitignore` files, respectively
40
40
 
41
41
  ## Creating tests
@@ -218,6 +218,15 @@ For example, filtering for the component 'Input'.
218
218
  npm run test-ui -- --visible --spec /Input
219
219
  ```
220
220
 
221
+ ### Running without animation effects
222
+
223
+ The `--no-animation` option is used to pack Enact without animation.
224
+ You can use this option to test the apps without animation effects.
225
+
226
+ ```bash
227
+ npm run test-ss -- --no-animation
228
+ ```
229
+
221
230
  ### Loading sample apps in a browser
222
231
 
223
232
  This requires that a server be running on port 3000. If you have globally installed the `serve`
@@ -47,7 +47,7 @@ module.exports.configure = (options) => {
47
47
  process.env.CHROME_DRIVER = chromeDriverVersion;
48
48
  }
49
49
  } catch (error) {
50
- console.log('ERROR: Cannnot find Chrome driver from Chrome ' + chromeVersionMajorNumber);
50
+ console.log('ERROR: Cannot find Chrome driver from Chrome ' + chromeVersionMajorNumber);
51
51
  process.env.CHROME_DRIVER = 2.44;
52
52
  }
53
53
  }
@@ -95,7 +95,7 @@ module.exports.configure = (options) => {
95
95
  // First, you can define how many instances should be started at the same time. Let's
96
96
  // say you have 3 different capabilities (Chrome, Firefox, and Safari) and you have
97
97
  // set maxInstances to 1; wdio will spawn 3 processes. Therefore, if you have 10 spec
98
- // files and you set maxInstances to 10, all spec files will get tested at the same time
98
+ // files, and you set maxInstances to 10, all spec files will get tested at the same time
99
99
  // and 30 processes will get spawned. The property handles how many capabilities
100
100
  // from the same test should run tests.
101
101
  //
@@ -224,8 +224,6 @@ module.exports.configure = (options) => {
224
224
  /**
225
225
  * Gets executed before test execution begins. At this point you can access to all global
226
226
  * variables like `browser`. It is the perfect place to define custom commands.
227
- * @param {Array.<Object>} capabilities list of capabilities details
228
- * @param {Array.<String>} specs List of spec file paths that are to be run
229
227
  */
230
228
  before: function () {
231
229
  require('expect-webdriverio');
@@ -0,0 +1,34 @@
1
+ const enactStrict = require('eslint-config-enact/strict');
2
+ const globals = require('globals');
3
+
4
+ const customGlobals = {
5
+ 'browser': true,
6
+ 'expect': true,
7
+ '$': true,
8
+ '$$': true
9
+ };
10
+
11
+ module.exports = [
12
+ ...enactStrict,
13
+ {
14
+ languageOptions: {
15
+ ecmaVersion: 'latest',
16
+ sourceType: 'module',
17
+ globals: {
18
+ ...globals.node,
19
+ ...globals.mocha,
20
+ ...customGlobals
21
+ },
22
+ parserOptions: {
23
+ ecmaFeatures: {
24
+ jsx: true
25
+ }
26
+ }
27
+ },
28
+ rules: {
29
+ 'max-nested-callbacks': 'off',
30
+ 'no-console': 'off',
31
+ 'react/forbid-foreign-prop-types': 'off' // proptypes not removed in storybook config
32
+ }
33
+ }
34
+ ];