diff --git a/tests/BasicTest.php b/tests/BasicTest.php new file mode 100644 index 0000000000..0f1b9f46d4 --- /dev/null +++ b/tests/BasicTest.php @@ -0,0 +1,18 @@ +assertTrue(true); + } +} diff --git a/tests/unit/Models/TransactionTypeTest.php b/tests/unit/Models/TransactionTypeTest.php new file mode 100644 index 0000000000..0a0daedcb9 --- /dev/null +++ b/tests/unit/Models/TransactionTypeTest.php @@ -0,0 +1,41 @@ +first(); + $this->assertTrue($transactionType->isWithdrawal()); + } + + public function testIsDeposit() + { + $transactionType = TransactionType::whereType(TransactionType::DEPOSIT)->first(); + $this->assertTrue($transactionType->isDeposit()); + } + + public function testIsTransfer() + { + $transactionType = TransactionType::whereType(TransactionType::TRANSFER)->first(); + $this->assertTrue($transactionType->isTransfer()); + } + + public function testIsOpeningBalance() + { + $transactionType = TransactionType::whereType(TransactionType::OPENING_BALANCE)->first(); + $this->assertTrue($transactionType->isOpeningBalance()); + } +}