How mcdcorp/opentest works
Main Components
• Sync Server – This is a Node.js application (located under the “server” directory) that orchestrates test execution, exposes both an HTTP API and a web user interface, and coordinates communication with test actors.
• Test Actor – This is a Java application (found under the “actor” directory) and is further divided into submodules (e.g., “actor/actor”, “actor/appium”, “actor/base”, “actor/selenium”). These subcomponents handle different test actions (covering API, Appium for mobile, Selenium for web testing, and common base functionality). Multiple test actors can be deployed on various machines, even across different networks.
• Test Repository – Although not directly represented as a single “repository” folder in the file tree, the README describes a test repository with a defined directory structure (including macros, scripts, templates, and tests) that holds the test assets under source control.
Relationships & Interactions
• The Sync Server acts as the central controller by issuing test execution commands via its HTTP API.
• Test Actors register with and listen to the Sync Server; they then execute test steps (depending on whether it is web testing using Selenium, mobile testing using Appium, or other actions) and report results back.
• The Test Repository is used to store test definitions, scripts, and other assets and is used by the Sync Server to create test sessions.
• In addition, illustrate the connection between the Sync Server and the Test Repository to indicate how test assets flow into test sessions.
Architectural Patterns & Design Principles
• There is a clear separation of concerns between the orchestration layer (Node.js sync server) and the test execution layer (Java test actors). This separation supports distributed and parallel testing (test actors potentially on different networks).
• The architecture leverages an API-driven design (HTTP endpoints for starting, monitoring, and managing test sessions) and emphasizes extensibility (through custom test actions in various languages and modules).
• Design principle where test actors do not require direct connectivity initiated by the server; instead, the actors “pull” instructions, which is critical for handling firewalled or isolated environments.
Relevant Technologies, Frameworks, and Libraries
• Node.js and related modules for the Sync Server.
• Java and Maven for compiling and packaging the Test Actor components.
• Selenium (for web testing) and Appium (for mobile testing) are reflected in the “actor/selenium” and “actor/appium” directories respectively.
• Libraries for HTTP handling, logging, and serialization (with segments in “actor/base”), as well as testing frameworks indicated by the testing sources.
• Build and configuration management files (under “build”, “package.json”, “pom.xml”, etc.) that help in deploying the system.