Skip to content

Commit

Permalink
Merge branch 'master' into feature/about-toolbar-extension
Browse files Browse the repository at this point in the history
  • Loading branch information
tkaik authored Jul 5, 2019
2 parents dcfa75c + 45b85df commit be2dd8d
Show file tree
Hide file tree
Showing 4 changed files with 50 additions and 28 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ All notable changes to AET will be documented in this file.
## Unreleased

**List of changes that are finished but not yet released in any final version.**
- [PR-479](https://github.com/Cognifide/aet/pull/479) Added Secure and HttpOnly flags for cookies. ([#477](https://github.com/Cognifide/aet/issues/477))
- [PR-506](https://github.com/Cognifide/aet/pull/506) About tab ([#475](https://github.com/Cognifide/aet/issues/475))


## Version 3.2.2

- [PR-507](https://github.com/Cognifide/aet/pull/507) Add option to match colors that are close to the target color in a grayscale space when comparing pixels with the LayoutComparator
Expand Down
12 changes: 6 additions & 6 deletions documentation/src/main/wiki/EnvironmentSetup.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@

There are two ways to setup the AET environment: basic and advanced.

##### basic
##### Basic

The basic setup makes use of [Vagrant](https://www.vagrantup.com/) to create a single virtual machine running Linux OS (currently CentOS 6.7). This virtual machine contains all AET services as well as all the software required to run them. In this configuration, tests are using a Linux version of the Firefox web browser. Please note that there are differences in web page rendering between Linux and Windows versions of Firefox and if you want to use its Windows version then you must refer to the advanced setup.
The basic setup makes use of [Vagrant](https://www.vagrantup.com/) to create a single virtual machine running Linux OS (currently CentOS 6.8). This virtual machine contains all AET services, except the Google Chrome browser and the Selenium Grid node process which needs to be started separately (e.g. on the host machine).

See **[[Basic Setup|BasicSetup]]** for more details.

The diagram below shows the basic AET setup.

![aet-setup-basic](assets/diagrams/aet-setup-basic.png)
![aet-setup-basic](assets/diagrams/aet-setup-with-vagrant.png)

##### advanced
##### Advanced

The advanced setup on the other hand makes use of two machines - one running a Linux OS and the other one running Windows, both complementary to each other. The linux machine hosts services such as MongoDB and ActiveMQ whereas the Windows machine hosts Karaf, the Browsermob proxy and Firefox. In this configuration tests run on a Windows version of the Firefox web browser.
The advanced setup on the other hand makes use of at least two separate machines - one running a Linux OS and the other ones running Windows. The Linux machine hosts all AET services and the Windows machines are hosting Selenium Grid node processes together with Google Chrome browser.

See **[[Linux and Windows Setup|LinuxAndWindowsSetup]]** for more details.
See **[[Advanced Setup|AdvancedSetup]]** for more details.

The diagram below shows the advanced AET setup.

Expand Down
60 changes: 39 additions & 21 deletions documentation/src/main/wiki/FAQ.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,18 @@
# FAQ
This section contains answers for frequently asked questions. If you can't find an answer to your question here
please use the [Issues Tool](https://github.com/Cognifide/aet/issues) to raise a question.
This section contains answers to frequently asked questions. If you can't find an answer to your question here
please use the [Issues Tool](https://github.com/Cognifide/aet/issues) to raise it.

- [1. Setup and first steps](#1-setup-and-first-steps)
- [1.1. What do I need to start using AET?](#11-what-do-i-need-to-start-using-aet)
- [1.2. I have an AET environment, how can I run tests?](#12-i-have-an-aet-environment-how-can-i-run-tests)
- [1.3. How can I integrate AET with continuous integration tools?](#13-how-can-i-integrate-aet-with-continuous-integration-tools)
- [1.4. I'm running AET for the first time. How will the tool know the patterns?](#14-im-running-aet-for-the-first-time-how-will-the-tool-know-the-patterns)
- [1.5. I would like to run my suite from my Windows machine and use some endpoint that is not my localhost. I get the unsuccessful status request with the code: 401. What should I do?](#15-i-would-like-to-run-my-suite-from-my-windows-machine-and-use-some-endpoint-that-is-not-my-localhost-i-get-the-unsuccessful-status-request-with-the-code-401-what-should-i-do)
- [2. Environment and software](#2-environment-and-software)
- [2.1. Which browser is used by AET?](#21-which-browser-is-used-by-aet)
- [2.2. Does AET use database for storing data?](#22-does-aet-use-database-for-storing-data)
- [2.3. I have a problem with missing fonts (my page is not English). What should I do?](#23-i-have-a-problem-with-missing-fonts-my-page-is-not-english-what-should-i-do)
- [2.4. What do I need the REST proxy for?](#24-what-do-i-need-the-rest-proxy-for)
- [3. User interface and reports](#3-user-interface-and-reports)
- [3.1 What browser should I use to browse AET reports?](#31-what-browser-should-i-use-to-browse-aet-reports)
- [3.2 I would like to compare pages between two environments/domains. How can I do that with the AET Tool?](#32-i-would-like-to-compare-pages-between-two-environmentsdomains-how-can-i-do-that-with-the-aet-tool)
Expand All @@ -21,6 +23,8 @@ please use the [Issues Tool](https://github.com/Cognifide/aet/issues) to raise a
- [3.7 How to get the latest report for the AET test suite?](#37-how-to-get-the-latest-report-for-the-aet-test-suite)
- [4. Best practices](#4-best-practices)
- [4.1 I want to check how my page looks on several devices - what is the best way do configure a suite?](#41-i-want-to-check-how-my-page-looks-on-several-devices---what-is-the-best-way-do-configure-a-suite)
- [5. Technology](#5-technology)
- [5.1 What technology does AET make use of?](#51-what-technology-does-aet-make-use-of)

## 1. Setup and first steps

Expand All @@ -30,51 +34,49 @@ already set up. See more information in [[Running Suite|RunningSuite#requirement
To setup AET you need [VirtualBox 5.2.18](https://www.virtualbox.org/wiki/Downloads) to run AET VM.
See more details in [[Basic Setup|BasicSetup]] section.


### 1.2. I have an AET environment, how can I run tests?
You need Maven and Java installed to run AET and Chrome browser to see reports.
You need the AET shell script to run AET and the Google Chrome browser to see reports.
See more information in [[Running Suite|RunningSuite#requirements]] section.
To start AET suite you need 2 XML files:
- [[pom.xml|RunningSuite#pomxml]] that defines how to run [[AET Client Application|ClientApplication]],
To start AET suite you need 2 files:
- [[aet.sh|RunningSuite#running-suite-with-bash-script]] that defines how to run [[AET Client Scripts|ClientScripts]],
- [[suite.xml|DefiningSuite]] that defines [[AET suite|SuiteStructure]].

To run suite simply execute this command:
To run the suite simply execute this command:

`mvn aet:run`
`./aet.sh <endpoint> [<suite_file_name>]`

from the directory where you have two above XML files.
from the directory where you have the two files mentioned above.

Next, you will see [[processing progress|TrackingProgress]]. After a
[[SUCCESSFUL BUILD|TrackingProgress#when-tests-successfully-finish---command-line]]
explore `target` directory and open `redirect.html` in Chrome browser file to see the [[report|SuiteReport]].

open `redirect.html` in the Google Chrome browser file to see the [[report|SuiteReport]].

### 1.3. How can I integrate AET with continuous integration tools?
AET tests are triggered by [[AET Maven Client Application|ClientApplication]]. Thanks to this you may simply
run `mvn aet:run` from your favourite CI tool (e.g. [Jenkins](https://jenkins.io/) or
AET tests are triggered by the [[AET shell script|ClientScripts]]. Thanks to this you may simply
run `./aet.sh <endpoint> [<suite_file_name>]` from your favourite CI tool (e.g. [Jenkins](https://jenkins.io/) or
[Bamboo](https://www.atlassian.com/software/bamboo)).

### 1.4. I'm running AET for the first time. How will the tool know the patterns?
When running AET for the first time AET has no patterns. The first collected screenshots will be treated
as patterns, so the first run will detect no changes. The same is true when a new test or url is added to
already existing suite - new records will have patterns collected during the first suite run.

### 1.5. I would like to run my suite from my Windows machine and use some endpoint that is not my localhost. I get the unsuccessful status request with the code: 401. What should I do?
When running tests from Windows there can be a problem with jq. The solution can be to run the same test from WSL (Windows Subsystem for Linux, e.g. Ubuntu).

---

## 2. Environment and software

### 2.1. Which browser is used by AET?
AET currently uses Firefox 38.6.0 ESR as default browser. Information about current versions of components
AET currently makes use of Google Chrome. Information about current versions of components
used by AET can be found in [[Third-party software used by system|SystemComponents#third-party-software-used-by-system]]
section.


### 2.2. Does AET use database for storing data?
Yes, AET uses [MongoDB](https://www.mongodb.org/) where all data collected during AET suite processing
is stored.


### 2.3. I have a problem with missing fonts (my page is not English). What should I do?
You can add custom fonts to AET virtual machine. To do so, place desired fonts inside
`usr/share/fonts` or `/usr/share/fonts/truetype` directories, AET's FireFox should use them.
Expand All @@ -83,13 +85,18 @@ Other idea is to install fonts with e.g.:
`yum groupinstall arabic-support`
See more details in answers for [this AET question](https://github.com/Cognifide/aet/issues/61).

### 2.4. What do I need the REST proxy for?
The REST proxy is required if you want to:
- test [Status codes|StatusCodesCollector],
- modify headers with the [Header modifier|HeaderModifier].

---

## 3. User interface and reports

### 3.1 What browser should I use to browse AET reports?
AET reports are dedicated and tested with Chrome browser, however they should also work fine with other
modern browsers like FireFox or Edge.
AET reports are dedicated and tested with Google Chrome browser, however they should also work fine with other
modern browsers like Mozilla FireFox or Microsoft Edge.

### 3.2 I would like to compare pages between two environments/domains. How can I do that with the AET Tool?
The AET System enables comparison of the same page (set of pages) between different environments (domains).
Expand All @@ -108,16 +115,13 @@ The string in `value` is [base64 encoded](https://en.wikipedia.org/wiki/Basic_ac
`username:password` string.
The other way is to use [[Login Modifier|LoginModifier]] that can pass simple login form.


### 3.4 How can I simulate another user agent?
Use [[Header Modifier|HeaderModifier]] to achieve that. Just add header modifier with key `'User-Agent'`
and requested value.


### 3.5 What can I do with elements that render differently each time a page is opened and it occurs in changes detected each time?
Use [[Hide Modifier|HideModifier]] to hide those elements with `css` or `xpath` selectors.


### 3.6 I want to check how my page behaves on mobile devices, how can I do that?
AET is not integrated with mobile devices. However, you may simulate mobile resolution and check if your
page changes its rendering breakpoints for different resolutions. Use [[Resolution Modifier|ResolutionModifier]]
Expand Down Expand Up @@ -160,3 +164,17 @@ Example test configuration may look like this:
<screen name="mobile"/>
</collect>
```

## 5. Technology

### 5.1. What technology does AET make use of?
The technology that AET makes use of comprises:
- Java 8 (with Apache Camel, jUnit 4, Mockito)
- Apache Karaf (OSGi)
- Apache ActiveMQ (JMS)
- MongoDB (NoSQL DB)
- Browsermob (HTTP Proxy)
- Selenium (Grid with Hub and Chrome nodes)
- Chef (cookbooks + Vagrant local instance on Oracle VirtualBox - see [AET Cookbook](https://github.com/Cognifide/aet-cookbook)
- Docker (with example Docker Swarm cluster config) - see [AET Docker](https://github.com/Skejven/aet-docker)
- AngularJS (Report app)
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@
<th>Name</th>
<th>Value</th>
<th>Expiry</th>
<th>HttpOnly</th>
<th>Secure</th>
</tr>
</thead>
<tbody>
Expand All @@ -64,6 +66,8 @@
<td>{{item.name}}</td>
<td>{{item.value}}</td>
<td>{{item.expiry}}</td>
<td><i ng-if="item.isHttpOnly" class="glyphicon glyphicon-ok"></i></td>
<td><i ng-if="item.isSecure" class="glyphicon glyphicon-ok"></i></td>
</tr>
</tbody>
</table>
Expand Down

0 comments on commit be2dd8d

Please sign in to comment.