Spike - Playwright implementation Plan

Approach

We want to seperate development activities from customer discovery and customer delivery. Customer Delivery we are delivering robust, high-quality code that is consistent, and reliable.

There are times when we have an objective where there is risks related to value - will customer pay for feature? usable - will customer be able to use the product, feasible - will the solution technically work? viable - will the feature(s) be viable for the business. In this case, we want to operate in a customer discovery mode where we are very rapidly validating and investigating something. Discovery prototypes are an order of magnitude smaller than Delivery work, and are designed to uncover the risk. The learnings and/or code from discovery can be leveraged when integrating into the commercial product.

 

image-20240625-160632.png

Feasibility Prototypes

  1. playwright inspector has better information for a particular element what are the best selectors.
    (i.e. for buttons → xpath, for anchor text → text )

    1. playwright calculation for css selector query is better than GTP recorder?

      1. → investigate if we can steal css selector query code from playwright codebase

  2. playwright code generator - contains recorder, selects elements and generates the test scripts.

    1. investigate if we can use and trigger the playwright code generator

    2. only useful if we end up using the generated code to the user

    3. NOT USEFUL FOR NO CODE FEATURES

    4. USEFUL FOR CODE GEN / AI GEN / IMPORT CODE

    5. Business model test - ???

      1. Ask customers if they prefer low code over ai generated code

    6. Technology test - ???

  3. playwright test results - exposes APIs for show test results of the session. It has a UI to show test results during execution.

  4. playwright UI mode - has a dashboard, pick dashboards, see variables, see logs etc.

    1. investigate to see if we use playwright UI mode as a debugger window feature.

  5. Scheduler | CI/CD invocation
    Investigate how to use playwright to be triggered by CI/CD from our environment. Are all the parameters the same? are there new ones? how can you run scripts in parallel?

  6. Desktop Application Executor
    Trial to see if we can wrap our execution service and run it locally on tester’s PC.

  7. OnPrem Configuration
    Investigate how to trigger scripts and dependency when everything is on a local server.

  8. Code Overhaul

    1. mitigation: investigate playwright wrapper

  9. Implementation approaches

    1. Have Playwright and Selenium available in parallel

      1. add a new set of services in backend to execute selenium

    2. Have a Playwright Adapter that meets Selenium functional spec

    3. Create independent application which communicates via websocket

      1. Seperate springboot project or angular or react project

      2. rebuild the record, executor part

      3. connect to playwright report data and create our own view

 

Current Architecture

 

gtp-current-architecture.drawio.svg

 

Target Architecture

Target architecture has playwright as a salmon-colored box of magic. We need to complete the feasibility prototypes above to have a detailed architecture.