From 5339052aac705f807b5442b57a7cfb4377105f16 Mon Sep 17 00:00:00 2001 From: Mark van den Broek Date: Wed, 4 Oct 2017 17:40:07 +0200 Subject: [PATCH] Added test for get with with default. --- tests/Support/CollectionTest.php | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tests/Support/CollectionTest.php b/tests/Support/CollectionTest.php index 3513ce5..154f1de 100644 --- a/tests/Support/CollectionTest.php +++ b/tests/Support/CollectionTest.php @@ -74,6 +74,14 @@ public function first_with_default() $this->assertEquals('default', $result); } + /** @test */ + public function get_with_default() + { + $data = new Collection; + $result = $data->get('foo', 'default'); + $this->assertEquals('default', $result); + } + /** @test */ public function last_returns_last_item_in_collection() {