JSPM

@uuv/dictionary

0.3.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 321
  • Score
    100M100P100Q88157F

UUV built-in set of cucumber sentences to write e2e tests

Package Exports

  • @uuv/dictionary

Readme

@uuv/dictionary

npm version License: MIT

This package provides a built-in set of Cucumber sentences for writing end-to-end tests with UUV. It includes translations in English and French, along with accessibility role-based sentence generation.

Features

  • Built-in Cucumber sentences for E2E testing
  • Support for multiple languages (English and French)
  • Role-based sentence generation for accessibility
  • Integration-ready with Cypress, Playwright, and Testing Library

Installation

npm install @uuv/dictionary

Usage

Import the dictionary in your test files:

import { getDefinedDictionary } from '@uuv/dictionary';

const dictionary = getDefinedDictionary('en'); // or 'fr' for French

Available Dictionaries

  • English (en)
  • French (fr)

Structure

The package contains:

  1. Base Sentences: General sentences for common actions
  2. Role-based Sentences: Context-specific sentences based on accessibility roles
  3. Language Support: Translations in English and French
  4. Accessibility Integration: Role-based sentence generation

Development

Building

Run nx build dictionary to build the library.

Running Unit Tests

Run nx test dictionary to execute the unit tests via Jest.

Linting

Run nx lint dictionary to lint the codebase.