aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/background/domains/GlobalMark.test.js (renamed from test/background/domains/global-mark.test.js)2
-rw-r--r--test/background/infrastructures/MemoryStorage.test.js (renamed from test/background/infrastructures/memory-storage.test.js)2
-rw-r--r--test/background/repositories/Mark.test.js (renamed from test/background/repositories/mark.test.js)4
-rw-r--r--test/background/repositories/Version.js (renamed from test/background/repositories/version.js)2
-rw-r--r--test/shared/urls.test.js9
-rw-r--r--test/shared/utils/keys.test.js20
6 files changed, 25 insertions, 14 deletions
diff --git a/test/background/domains/global-mark.test.js b/test/background/domains/GlobalMark.test.js
index bdf1ea6..ed636e9 100644
--- a/test/background/domains/global-mark.test.js
+++ b/test/background/domains/GlobalMark.test.js
@@ -1,4 +1,4 @@
-import GlobalMark from 'background/domains/global-mark';
+import GlobalMark from 'background/domains/GlobalMark';
describe('background/domains/global-mark', () => {
describe('constructor and getter', () => {
diff --git a/test/background/infrastructures/memory-storage.test.js b/test/background/infrastructures/MemoryStorage.test.js
index 8871749..95d3780 100644
--- a/test/background/infrastructures/memory-storage.test.js
+++ b/test/background/infrastructures/MemoryStorage.test.js
@@ -1,4 +1,4 @@
-import MemoryStorage from 'background/infrastructures/memory-storage';
+import MemoryStorage from 'background/infrastructures/MemoryStorage';
describe("background/infrastructures/memory-storage", () => {
it('stores values', () => {
diff --git a/test/background/repositories/mark.test.js b/test/background/repositories/Mark.test.js
index 4f71f62..2a5b099 100644
--- a/test/background/repositories/mark.test.js
+++ b/test/background/repositories/Mark.test.js
@@ -1,5 +1,5 @@
-import MarkRepository from 'background/repositories/mark';
-import GlobalMark from 'background/domains/global-mark';
+import MarkRepository from 'background/repositories/MarkRepository';
+import GlobalMark from 'background/domains/GlobalMark';
describe('background/repositories/mark', () => {
let repository;
diff --git a/test/background/repositories/version.js b/test/background/repositories/Version.js
index 8510ae6..c7fa88b 100644
--- a/test/background/repositories/version.js
+++ b/test/background/repositories/Version.js
@@ -1,4 +1,4 @@
-import VersionRepository from 'background/repositories/version';
+import VersionRepository from 'background/repositories/Version';
describe("background/repositories/version", () => {
let versionRepository;
diff --git a/test/shared/urls.test.js b/test/shared/urls.test.js
index f004b3d..f2950b6 100644
--- a/test/shared/urls.test.js
+++ b/test/shared/urls.test.js
@@ -44,14 +44,5 @@ describe("shared/commands/parsers", () => {
.to.equal('http://google.com');
});
});
-
- describe('#homepageUrls', () => {
- it('split urls', () => {
- expect(parsers.homepageUrls('https://google.com/'))
- .to.deep.equal(['https://google.com/']);
- expect(parsers.homepageUrls('yahoo.com|https://i-beam.org/'))
- .to.deep.equal(['http://yahoo.com', 'https://i-beam.org/']);
- });
- });
});
diff --git a/test/shared/utils/keys.test.js b/test/shared/utils/keys.test.js
index 770b530..b2ad3cb 100644
--- a/test/shared/utils/keys.test.js
+++ b/test/shared/utils/keys.test.js
@@ -35,6 +35,17 @@ describe("keys util", () => {
expect(k.altKey).to.be.false;
expect(k.metaKey).to.be.false;
});
+
+ it('returns from keyboard input Crtl+Space', () => {
+ let k = keys.fromKeyboardEvent({
+ key: ' ', shiftKey: false, ctrlKey: true, altKey: false, metaKey: false
+ });
+ expect(k.key).to.equal('Space');
+ expect(k.shiftKey).to.be.false;
+ expect(k.ctrlKey).to.be.true;
+ expect(k.altKey).to.be.false;
+ expect(k.metaKey).to.be.false;
+ });
});
describe('fromMapKey', () => {
@@ -100,6 +111,15 @@ describe("keys util", () => {
expect(key.altKey).to.be.false;
expect(key.metaKey).to.be.false;
});
+
+ it('returns for Ctrl+Esc', () => {
+ let key = keys.fromMapKey('<C-Space>');
+ expect(key.key).to.equal('Space');
+ expect(key.shiftKey).to.be.false;
+ expect(key.ctrlKey).to.be.true;
+ expect(key.altKey).to.be.false;
+ expect(key.metaKey).to.be.false;
+ });
});
describe('fromMapKeys', () => {