Skip to content

Commit f053f16

Browse files
committed
Changed scratchpad to ruby
1 parent 7d96017 commit f053f16

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

scratchpad.txt scratchpad.rb

+17-1
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,24 @@
2929
{:something => actual({}) }
3030
{:something => empty_hash }
3131

32-
Slightly unintuitive behaviour: {} matches any hash, but [] only matches an empty array (or does now we've changed the code). Should [] match any array? How do we then specify an empty array?
32+
# Slightly unintuitive behaviour: {} matches any hash, but [] only matches an empty array (or does now we've changed the code). Should [] match any array? How do we then specify an empty array?
3333

3434
{:something => literal([]) }
3535
{:something => actual([]) }
3636
{:something => empty_array }
37+
38+
39+
Pact.build do
40+
{
41+
status: 200,
42+
headers: exactly({
43+
44+
}),
45+
body: including({
46+
age: literal('12'),
47+
phoneNumber: example("0415 134 234", /\d{4} \d{3} \d{3}/),
48+
favouriteColors:
49+
})
50+
}
51+
52+
end

0 commit comments

Comments
 (0)