We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3cc7650 commit 1b40960Copy full SHA for 1b40960
tests/Feature/HasBinaryUuidTest.php
@@ -96,6 +96,22 @@ public function it_decodes_columns_besides_primary_uuid_when_turned_to_an_array(
96
$this->assertEquals($modelArray['relation_uuid'], $model->relation_uuid_text);
97
}
98
99
+ /** @test */
100
+ public function it_should_use_custom_suffix_when_specified()
101
+ {
102
+ $uuid = Uuid::uuid1();
103
+
104
+ $model = $this->createModel($uuid);
105
106
+ $model->setUuidSuffix('_str');
107
108
+ $modelArray = $model->toArray();
109
110
+ $this->assertNotNull($model);
111
+ $this->assertTrue(array_key_exists('uuid', $modelArray));
112
+ $this->assertEquals($modelArray['uuid'], $model->uuid_str);
113
+ }
114
115
/** @test */
116
public function it_can_query_multiple_relations_with_scope()
117
{
0 commit comments