-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
69 lines (64 loc) · 2.29 KB
/
index.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<!DOCTYPE html>
<html>
<head>
<title>Parcel Sandbox</title>
<meta charset="UTF-8" />
</head>
<body>
<h1>Terms of the Exercise</h1>
<ul>
<li>Try and stay away from libraries if possible</li>
<li>
You can take as long as you like to complete the exercise, but for an
indicative timescale we expect a senior developer can accomplish this in
an hour.
</li>
<li>
You may use online resources to assist you with specific techniques,
syntax etc. but please do not just copy code.
</li>
</ul>
<h1>The Challenge</h1>
<p>
The aim of the exercise is to demonstrate your problem solving and
understanding of JavaScript by implementing something found in every unit
testing tool - an "assertEquals" method.
</p>
<ul>
<li>
Fill in the "assertEquals" function such that it will correctly compare
the passed "expected" vs "actual" parameters.
</li>
<li>You may add more functions.</li>
<li>
We are big on TDD, so we expect you to complete this test using this
approach.
</li>
<li>
Credit will be given for approach, correctly identifying "failed"
assertEquals, <b>clean, testable</b> code and coding style.
</li>
<li>
The set of tests provided isn't exhaustive - there are cases that they
don't handle. We expect you to add more tests.
</li>
</ul>
<h1>Expected Result</h1>
The following tests should "fail":
<strong>02, 03, 04, 07, 08 and 09</strong> - and the failures should be
reported using the provided mechanism.<br />
We expect the following output for the lsit of tests we have provided, but
we also expect you to add more tests:
<ul class="expected">
<li>Test 02: Expected "abcdef" found "abc"</li>
<li>Test 03: Expected type Array but found type Object</li>
<li>Test 04: Expected array length 2 but found 3</li>
<li>Test 07: Expected propB.propA[1].propB "b" but found "c"</li>
<li>Test 08: Expected propB.propC but was not found</li>
<li>Test 09: Expected type Null but found type Object</li>
</ul>
<h1>Output</h1>
<ul class="output" id="messages"></ul>
<script src="src/index.js"></script>
</body>
</html>