From ca6d06a5081b22362c65f2d85a80c9591d7dc903 Mon Sep 17 00:00:00 2001 From: David Llop Date: Wed, 25 Jul 2018 13:26:20 +0200 Subject: [PATCH 1/2] Fix typo in Testing docs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit I tried with assertReplies but since the content is not an array I was having an error. My string was split into single characters and being used as array 😅. Also there was a ' missing --- testing.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/testing.md b/testing.md index 0859460..20389de 100644 --- a/testing.md +++ b/testing.md @@ -265,7 +265,7 @@ public function testStartConversation() { $this->bot ->receivesEvent('event_name') - ->assertReplies('Received event'); + ->assertReply('Received event'); } ``` @@ -276,7 +276,7 @@ public function testStartConversation() { $this->bot ->receivesEvent('event_name', ['key' => 'value']) - ->assertReplies('Received event); + ->assertReply('Received event'); } ``` From 903340f31d93eeee267b72b0c0ee30feb0412b7a Mon Sep 17 00:00:00 2001 From: David Llop Date: Wed, 25 Jul 2018 13:33:36 +0200 Subject: [PATCH 2/2] Fix anchor link for Simulating User Messages --- testing.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/testing.md b/testing.md index 20389de..31500cf 100644 --- a/testing.md +++ b/testing.md @@ -2,7 +2,7 @@ - [Introduction](#introduction) - [Testing Multiple Replies](#testing-multiple-replies) -- [Simulating User Messages](#simulationg-user-messages) +- [Simulating User Messages](#simulating-user-messages) - [Available Assertions](#available-assertions) - [Testing Conversations](#testing-conversations) - [Testing Events](#testing-events) @@ -10,6 +10,7 @@ > {callout-info} The BotMan testing features are only available in combination with [BotMan Studio](/__version__/botman-studio). + ## Introduction Like Laravel, BotMan is build with testing in mind. Every part of it is well tested and this is the only way to keep such a big project running properly.