Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This was the test set by Iress as a take home test

Toy Robot

This guide explains how to test the Toy Robot simulator using the provided test files and interactive mode. This has been written in C# .NET 8.0

Ideally download as a zip as the file structure will remain as planned.

Requirements

.Net SDK

Required to run: .NET 8.0 SDK installed - Choose the SDK (not just runtime or desktop)

Not 100% necessary as you can run dotnet run - Build Project (dotnet build)

Test Files Included The project includes two test files in the root directory:

robot-test.txt - Basic functionality tests prodivded with the brief
robot-test2.txt - Comprehensive in-depth testing

Testing Methods - All these methods should be used in a command prompt opened in Toy_Robot Folder

Method 1: Using Provided Test Files

Quick Test - Open a console window in the project folder (Toy_Robot)

dotnet run -- robot-test.txt

Comprehensive Test (In-Depth)

dotnet run -- robot-test2.txt

This is the expected outcome from running a test file:

Expected output of a test file

Method 2: Custom Test Files

Create your own test file and run it:
dotnet run -- "C:\Code\Toy Robot\Toy_Robot\myTests.txt"

Running Automated Tests

Download the ToyRobotTest folder and place it in the same folder as the main project.

This is what the outcome of the test file is, though the first time it is run, it may show some warnings but will still finish:

Expected output of automated tests, the first run may contain warnings, subsequent runs should look like this

Execute the automated test suite in the Toy_Robot folder (Important):
dotnet test

How the table is layed out

Y
4 [ ][ ][ ][ ][ ] ← NORTH edge
3 [ ][ ][ ][ ][ ]
2 [ ][ ][ ][ ][ ]
1 [ ][ ][ ][ ][ ]
0 [0][ ][ ][ ][4] ← SOUTH edge (Y=0)
0 1 2 3 4 - X
↑--------- ↑
WEST--- EAST
edge---- edge

About

Iress Test Project

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages