Make sure when a note has no content, null is saved to the db, not ''

This commit is contained in:
Jonny Barnes 2018-01-06 23:12:03 +00:00
parent 56d180729e
commit ae2dc99069
3 changed files with 8 additions and 1 deletions

View file

@ -146,12 +146,14 @@ class SwarmTest extends TestCase
$response
->assertStatus(201)
->assertJson(['response' => 'created']);
//dump($response->__get('headers')->get('location'));
$this->assertDatabaseHas('places', [
'external_urls' => '{"foursquare": "https://foursquare.com/v/654321"}'
]);
$this->assertDatabaseHas('notes', [
'swarm_url' => 'https://www.swarmapp.com/checkin/def'
]);
$this->get($response->__get('headers')->get('location'))->assertSee('round pushpin');
}
public function test_faked_ownyourswarm_request_saves_just_post_when_error_in_checkin_data()