A fully open source & end-to-end encrypted note taking alternative to Evernote.
TypeScript asp-net-coredotnet-coreelectronfosshacktoberfestnote-managmentnote-takingnote-taking-appnotebooknotesnotes-appopen-sourceopensourceprivacyproductivityreactreact-nativereactjsself-hosted
cleanup tests
ammarahm-ed296e82631aa5
diff --git a/apps/mobile/e2e/tests/index.e2e.js b/apps/mobile/e2e/tests/index.e2e.jsindex aaeb013f7..fa3f6f691 100644--- a/apps/mobile/e2e/tests/index.e2e.js+++ b/apps/mobile/e2e/tests/index.e2e.js@@ -1,9 +1,6 @@-const { notesnook } = require("../test.ids");-const { sleep } = require("./utils.test");+const detox = require("detox");+const { LaunchApp } = require("./misc.e2e");-it('App initialization', async () => {- device.launchApp();- console.log('sleeping after launch');- await sleep(5000);- await expect(element(by.id(notesnook.ids.default.root))).toBeVisible();+it('App Launch', async () => {+ await LaunchApp();});\ No newline at end of filediff --git a/apps/mobile/e2e/tests/misc.e2e.js b/apps/mobile/e2e/tests/misc.e2e.jsindex bf575d8c9..f0ed3c9f9 100644--- a/apps/mobile/e2e/tests/misc.e2e.js+++ b/apps/mobile/e2e/tests/misc.e2e.js@@ -1,40 +1,41 @@-const { notesnook } = require("../test.ids");-const { sleep } = require("./utils.test");--it('App initialization', async () => {- await expect(element(by.id(notesnook.ids.default.root))).toBeVisible();-});+const {notesnook} = require('../test.ids');+const {sleep} = require('./utils.test');+export async function LaunchApp() {+ device.launchApp();+ await sleep(5000);+ await expect(element(by.id(notesnook.ids.default.root))).toBeVisible();+}+/*it('Drawer Navigation', async () => {- let menu = element(by.id(notesnook.ids.default.header.buttons.left));- await menu.tap();- await sleep(100)- await element(by.text('Notebooks')).tap();- menu.tap();- await sleep(100)- await element(by.text('Favorites')).tap();- menu.tap();- await sleep(100)- await element(by.text('Trash')).tap();- menu.tap();- await sleep(100)- await element(by.text('Tags')).tap();- menu.tap();- await sleep(100)- await element(by.text('Settings')).tap();- });-+ let menu = element(by.id(notesnook.ids.default.header.buttons.left));+ await menu.tap();+ await sleep(100);+ await element(by.text('Notebooks')).tap();+ menu.tap();+ await sleep(100);+ await element(by.text('Favorites')).tap();+ menu.tap();+ await sleep(100);+ await element(by.text('Trash')).tap();+ menu.tap();+ await sleep(100);+ await element(by.text('Tags')).tap();+ menu.tap();+ await sleep(100);+ await element(by.text('Settings')).tap();+});it('Dark Mode', async () => {- let menu = element(by.id(notesnook.ids.default.header.buttons.left));- menu.tap();- await sleep(100)- let nightmode = element(by.id(notesnook.ids.menu.nightmode))- await sleep(100)- await nightmode.tap();- await sleep(100)- await nightmode.tap();- await sleep(100)- menu.tap();- });-+ let menu = element(by.id(notesnook.ids.default.header.buttons.left));+ menu.tap();+ await sleep(100);+ let nightmode = element(by.id(notesnook.ids.menu.nightmode));+ await sleep(100);+ await nightmode.tap();+ await sleep(100);+ await nightmode.tap();+ await sleep(100);+ menu.tap();+});+ */\ No newline at end of filediff --git a/apps/mobile/e2e/tests/utils.test.js b/apps/mobile/e2e/tests/utils.test.jsindex 31ff5595b..9e5626bc3 100644--- a/apps/mobile/e2e/tests/utils.test.js+++ b/apps/mobile/e2e/tests/utils.test.js@@ -1,4 +1,7 @@export const sleep = (duration) =>-new Promise((resolve) => setTimeout(() => resolve(), duration));+new Promise((resolve) => setTimeout(() => {+ console.log('Sleeping for ' + (duration/1000) + " secs");+ resolve();+}, duration));//"\\.e2e\\.js$",\ No newline at end of file