From f23a8ee4d356645ae3f91862552b256f230c6bcb Mon Sep 17 00:00:00 2001
From: Florian Dold <florian@dold.me>
Date: Mon, 11 Oct 2021 10:58:55 +0200
Subject: anastasis-webui: first commit

---
 packages/anastasis-webui/tests/header.test.tsx | 12 ++++++++++++
 1 file changed, 12 insertions(+)
 create mode 100644 packages/anastasis-webui/tests/header.test.tsx

(limited to 'packages/anastasis-webui/tests/header.test.tsx')

diff --git a/packages/anastasis-webui/tests/header.test.tsx b/packages/anastasis-webui/tests/header.test.tsx
new file mode 100644
index 000000000..b2cfc2f4d
--- /dev/null
+++ b/packages/anastasis-webui/tests/header.test.tsx
@@ -0,0 +1,12 @@
+import { h } from 'preact';
+import Header from '../src/components/header';
+// See: https://github.com/preactjs/enzyme-adapter-preact-pure
+import { shallow } from 'enzyme';
+
+describe('Initial Test of the Header', () => {
+    test('Header renders 3 nav items', () => {
+        const context = shallow(<Header />);
+        expect(context.find('h1').text()).toBe('Preact App');
+        expect(context.find('Link').length).toBe(3);
+    });
+});
-- 
cgit v1.2.3

