aboutsummaryrefslogtreecommitdiffstats
path: root/tests/unit/includes/AccountTest.php
diff options
context:
space:
mode:
authorMario <mario@mariovavti.com>2024-01-06 16:34:39 +0000
committerMario <mario@mariovavti.com>2024-01-06 16:34:39 +0000
commita36de8ba1a27204667413760c53f783ba60f22a7 (patch)
treefa219c32ebe5d8cad86dccc6b26b04ed6c22145b /tests/unit/includes/AccountTest.php
parentc73518d8ec562aed63223c668a43d9cda152cb9d (diff)
parente3d30763dabdf12f961ed3d1d7cf4eaee44c65a9 (diff)
downloadvolse-hubzilla-a36de8ba1a27204667413760c53f783ba60f22a7.tar.gz
volse-hubzilla-a36de8ba1a27204667413760c53f783ba60f22a7.tar.bz2
volse-hubzilla-a36de8ba1a27204667413760c53f783ba60f22a7.zip
Merge branch 'tests/fix-db-and-ci-integration' into 'dev'
tests: Integrate the DB in "unit" tests. See merge request hubzilla/core!2081
Diffstat (limited to 'tests/unit/includes/AccountTest.php')
-rw-r--r--tests/unit/includes/AccountTest.php12
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/unit/includes/AccountTest.php b/tests/unit/includes/AccountTest.php
new file mode 100644
index 000000000..d123a0c70
--- /dev/null
+++ b/tests/unit/includes/AccountTest.php
@@ -0,0 +1,12 @@
+<?php
+/**
+ * Tests for account handling helper functions.
+ */
+
+class AccountTest extends Zotlabs\Tests\Unit\UnitTestCase {
+ public function test_get_account_by_id_returns_existing_account() {
+ $account = get_account_by_id(42);
+ $this->assertNotFalse($account);
+ $this->assertEquals($this->fixtures['account'][0]['account_email'], $account['account_email']);
+ }
+}