Skip to content

Repository files navigation

FantasyCharacterForgeTests

This test suite automates the verification of the character creation process on the FantasyCharacterForge platform using Playwright. It covers form filling, race/class selection, validation of mandatory fields, image uploads, and proper distribution of skill points.

Features Tested:

  • Character Creation Form

Automates the process of filling out the character creation form, including details like:

Name, dynasty, family, age, weight Realm, faith, motivations Biography and equipment Race and Class Selection Verifies that the race and class descriptions are displayed correctly and that the user can select and confirm their choices.

  • Mandatory Field Validation

Ensures that mandatory fields like the character name are validated, and appropriate error messages are displayed if any required field is left empty.

  • Image Upload

Checks that the image upload functionality works correctly and the image is saved as part of the character creation process.

  • Skill Points Allocation

Tests the functionality for allocating skill points to attributes like strength, dexterity, and intelligence, verifying the distribution and ensuring it reflects accurately in the character's profile.

  • Character Details Validation

After character creation, the test ensures that all entered details (name, dynasty, biography, etc.) are displayed correctly.

Technologies Used:

Playwright: For browser automation and UI testing.

Node.js: Test environment for running Playwright scripts.

Links

Commands

  • check NodeJS version
    node -v

  • new project with Playwright
    npm init playwright@latest

  • record tests for given site
    npx playwright codegen http://localhost:3000/ (First, you need to set up the project locally: FantasyCharacterForge)

  • or npx playwright codegen https://our3worlds.pl/creatorproject/

  • run tests without browser GUI
    npx playwright test

  • run tests with browser GUI
    npx playwright test --headed

  • view report
    npx playwright show-report

Playwright Config modifications

  • config file playwright.config.ts
  • disable browsers, i.e. Firefox
    // {
    //   name: 'firefox',
    //   use: {
    //     ...devices['Desktop Firefox'],
    //   },
    // },

About

This project suite automates the verification process for character creation in the FantasyCharacterForge platform using Playwright for end-to-end testing. It covers form validation (e.g., age, race/class selection), mandatory fields, file uploads, and the proper distribution of skill points.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages