How to migrate from Hermione to Testplane
warning
If in your project Hermione is younger than the v8.x version, then read first:
- «How to update hermione to the v.4.x»;
- «How to update hermione to the v.5.x»;
- «How to update hermione to the v.6.x»;
- «How to update hermione to the v.7.x»;
- «How to update hermione to the v.8.x».
We recommend updating Hermione step by step, ensuring at each stage that all project tests are executed correctly.
What has changed?
This project was formerly known as "Hermione", but eventually some copyright and trademark issues surfaced, leading to the decision to rebrand. After some discussion, we settled on "Testplane" as the official new title. Considering this change as merely a rebranding, we've proceeded with the existing version count instead of starting anew. Thus, Testplane v8.x
is a drop-in replacement for Hermione v8.x
.
How to move?
1. Replace hermione deps with tesplane in package.json
npm uninstall hermione
npm install -D testplane
2. Replace "hermione" with "testplane" in compilerOptions.types field of your tsconfig.json file
{
"compilerOptions": {
"types": [
"testplane"
]
}
}
3. Replace all imports, requires and declarations
import ... from "hermione"
→import ... from "testplane"
require("hermione")
→require("testplane")
declare module "hermione"
→declare module "testplane"
4. Optional changes list (these are not required, but recommended)
- use
testplane
binary instead ofhermione
binary; - rename
.hermione.conf.ts
,.hermione.conf.js
configs to.testplane.conf.ts
,.testplane.conf.js
; - use
globalThis.testplane
helper instead ofglobalThis.hermione
; - use
testplane_
environment variables instead ofhermione_
environment variables; - use testplane field instead of hermione on event handlers;
- use TestplaneCtx instead of
HermioneCtx
type; - use
executionContext.testplaneCtx
as browser property instead ofexecutionContext.hermioneCtx
; - if you use default screenshotsDir value, rename "hermione/screens" directory to "testplane/screens" or specify the value "hermione/screens" explicitly;
- if you use default sets.files value, move your tests from "hermione" to "testplane" directory or specify the value "hermione" explicitly.
Support
If you encounter any problems during the migration or have any questions, come to github issues - and we will definitely help you!