Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions docs/content/4.Spectre/1.getting-started/1.introduction.md

This file was deleted.

63 changes: 63 additions & 0 deletions docs/content/4.Spectre/1.getting-started/1.overview.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
Spectre πŸ”
======
The Spectre CLI is used to scaffold web & mobile automation projects quickly and easily. The CLI leverages the use of the [WebDriverIO](https://webdriver.io/) framework to enable QA and software engineers to verify the quality of mobile or web applications being developed. The CLI also provides examples for you to quickly run to be able to get going with automated testing!

The CLI also uses the Page Object Pattern which provides a layer of abstraction between the test files and the pages/screens actually being tested. For more information on page objects, you can read [here](https://www.martinfowler.com/bliki/PageObject.html).

The CLI also provides tooling support to easily create test scripts to verify functionality through the use of [Mocha](https://mochajs.org/) and [Chai](https://www.chaijs.com/).

A project created from Spectre also has access to different testing services such as:
- [Appium](https://appium.io/)
- [BrowserStack](https://www.browserstack.com/)
- [Allure](https://docs.qameta.io/allure/)

# System Requirements
## Mac
1. [Node](https://nodejs.org/en/)
2. [Java](https://www.java.com/en/download/help/mac_install.html)

## Windows
1. [Node](https://nodejs.org/en/)
2. [Java](https://www.java.com/en/download/windows_manual.jsp)

For web automation, a web browser for web automation (Google Chrome, Firefox, Safari, Edge or a combination of all of the above).

For mobile automation, you will need the following installed on your machine:

### Windows
- Android SDK and access to emulators: https://developer.android.com/studio/install#windows
- Download Appium https://github.com/appium/appium-desktop/releases/download/v1.22.3-4/Appium-Server-GUI-windows-1.22.3-4.exe

### Mac
- Android SDK and access to emulators: https://developer.android.com/studio/install#mac
- Xcode configuration https://developer.apple.com/support/xcode/ & https://www.freecodecamp.org/news/install-xcode-command-line-tools/
- Download Appium https://github.com/appium/appium-desktop/releases/download/v1.22.3-4/Appium-Server-GUI-mac-1.22.3-4.dmg

NB - You can double check your appium installation by installing Appium Doctor using the command below:
```
npm install -g appium-doctor
```

Then you can verify if your Android or iOS setup is correct (pass either --ios or --android if you want to see if the installation of a specific platform is correct):
```
appium-doctor
```

Please look at this Appium reference [here](https://appium.io/docs/en/about-appium/getting-started/#starting-appium) for more details.

### Recommended tools
We recommend the use of Visual Studio Code as they provide autocompletion for many of the WebDriverIO commands being used by the scaffolded project.


# Installation
Installing the spectre plugin can be done with the following command:
```bash
$ frontier plugins:install @rdfrontier/plugin-qa
```

Verify installation is working by typing:
The help menu can be accessed with the command:

```bash
frontier qa --help
```
119 changes: 119 additions & 0 deletions docs/content/4.Spectre/2.cli-commands/1.usage.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,119 @@
# Usage

The format for running an Spectre command is generally:

```bash
frontier qa:COMMAND
```
## Commands
<!-- custom-commands -->

- [`frontier qa:create-mobile-project [NAME]`](#frontier-qa-create-mobile-project-name)
- [`frontier qa:create-page-object [NAME]`](#frontier-qa-create-page-object-name)
- [`frontier qa:create-project [NAME]`](#frontier-q-create-project-name)
- [`frontier qa:create-screen-object [NAME]`](#frontier-qacreate-screen-object-name)
- [`frontier qa:create-test [NAME]`](#frontier-qa-create-test-name)
- [`frontier qa --help [COMMAND]`](#frontier-qa-help-command)


### `frontier qa:create-mobile-project [NAME]`

Create a new WDIO project for Mobile

```
USAGE
$ frontier qa:create-mobile-project [NAME]

ARGUMENTS
NAME Name of the project to be created

OPTIONS
-h, --help show CLI help
```

## `frontier qa:create-page-object [NAME]`

Create a new page object file

```
USAGE
$ frontier qa:create-page-object [NAME]

ARGUMENTS
NAME Name of the page object file to be created

OPTIONS
-h, --help show CLI help

EXAMPLE
$ frontier qa:create-page-object
Running this add command!
```

## `frontier qa:create-project [NAME]`

Create a new WDIO project

```
USAGE
$ frontier qa:create-project [NAME]

ARGUMENTS
NAME Name of the project to be created

OPTIONS
-h, --help show CLI help
```

## `frontier qa:create-screen-object [NAME]`

Create a new screen object file

```
USAGE
$ frontier qa:create-screen-object [NAME]

ARGUMENTS
NAME Name of the page object file to be created

OPTIONS
-h, --help show CLI help

EXAMPLE
$ frontier qa:create-screen-object
Running this add command!
```

## `frontier qa:create-test [NAME]`

Create a new test file

```
USAGE
$ frontier qa:create-test [NAME]

ARGUMENTS
NAME Name of the test file to be created

OPTIONS
-h, --help show CLI help

EXAMPLE
$ frontier qa:create-test
<name-of-file-without-extension>
```

## `frontier qa:[COMMAND] --help `

display help for spectre

```
USAGE
$ frontier qa:[COMMAND] --help

ARGUMENTS
COMMAND command to show help for

OPTIONS
--all see all commands in CLI
```