From ae63e7c017c60c2af9e809fe0e91b31f46e6b6e2 Mon Sep 17 00:00:00 2001 From: Corey Taylor Date: Mon, 21 Sep 2020 04:12:58 -0500 Subject: [PATCH] Dump table when record not found --- tests/TestCase/ORM/Behavior/TranslateBehaviorTest.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/tests/TestCase/ORM/Behavior/TranslateBehaviorTest.php b/tests/TestCase/ORM/Behavior/TranslateBehaviorTest.php index 0588304da9b..22782ee1b45 100644 --- a/tests/TestCase/ORM/Behavior/TranslateBehaviorTest.php +++ b/tests/TestCase/ORM/Behavior/TranslateBehaviorTest.php @@ -834,7 +834,11 @@ public function testGetAssociationNotDirtyBelongsTo() $authors->setLocale('eng'); - $entity = $table->get(1); + try { + $entity = $table->get(1); + } catch (\Cake\Datasource\Exception\RecordNotFoundException $e) { + var_dump($table->find('all')->all()->toArray()); + } $this->assertNotEmpty($entity); $entity = $table->loadInto($entity, ['Authors']); $this->assertFalse($entity->isDirty());