Skip to content

Commit fdf6214

Browse files
committed
improve some tests
1 parent 9066a82 commit fdf6214

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

tests/AttributeTest.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,7 @@
8686
$product->attachAttribute('role', $value = 'developer');
8787

8888
assertDatabaseCount('products', 1);
89+
assertDatabaseCount('attributes', 1);
8990
assertNotEmpty($product->hasAttributeValue($value));
9091
});
9192

@@ -94,6 +95,7 @@
9495
$product->attachAttribute($title = 'role', 'developer');
9596

9697
assertDatabaseCount('products', 1);
98+
assertDatabaseCount('attributes', 1);
9799
assertNotEmpty($product->hasAttributeTitle($title));
98100
});
99101

@@ -103,6 +105,7 @@
103105
$product->deleteAttribute($title, $value);
104106

105107
assertDatabaseCount('products', 1);
108+
assertDatabaseCount('attributes', 0);
106109
});
107110

108111
test('test can delete all attributes of one model', function () {

0 commit comments

Comments
 (0)