In this module we will download and deploy the test harness.
We need to clone the test harness repo:
cd ~/
git clone https://github.com/StevenDavid/win403-testharness.git
Next we will need to update the “aws-ecs-tools-defaults.json” file. Specifically we want to update the following two fields:
task-definition-task-role: update the {account Id} with your current account. You can get the current account ID by running the following command:
aws sts get-caller-identity --output text --query Account
Let’s get docker working on Cloud9 so that we can publish containers
sudo yum install -y docker
sudo usermod -a -G docker ec2-user
sudo service docker start
Now we want to deploy the test harness to ECS. Run the following command from the same directory as the “aws-ecs-tools-defaults.json” file:
cd ~/win403-testharness/src
dotnet ecs deploy-service
The test harness has three main components:
Next is the run tests api commands. Assuming the same IP, those commands look like this:
http://167.2.1.3/api/TestHarness/test/{Number of test}/{Parrellel runs in a single test}
Lastly we have the reset data feature. This allows the removal of all previous tests. Again Assuming the same IP as above the API is located at:
http://167.2.1.3//api/TestHarness/reset/