Skip to content

Firefly III: a personal finances manager

Another attempt at fixing some tests. I'm probably searching in the wrong direction with this.

James Cole8520a5002f8c
diff --git a/tests/factories/all.php b/tests/factories/all.php
index c12158c9cc..44a7ca5469 100644
--- a/tests/factories/all.php
+++ b/tests/factories/all.php
@@ -50,8 +50,8 @@ FactoryMuffin::define(
'FireflyIII\Models\AccountType', [
'type' => function () {
$types = ['Expense account', 'Revenue account', 'Asset account'];
-
- return $types[rand(0, 2)];
+ $count = DB::table('account_types')->count();
+ return $types[$count];
},
'editable' => 1,
]