mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-09-11 19:17:09 +03:00
Decaffeinate the following files. * atom-protocol-handler * babel-spec * buffered-node-process * buffered-process * clipboard * context-menu-manager * decoration-manager * default-directory-provider * deserializer-manager * file-system-blob-store * keymap-extensions * menu-manager * module-cache * pane-axis-element * pane-container-element * pane-element * package-spec * squirel-update * styles-element-spec * task-spec * typescript-spec * spec-helper-platform
24 lines
736 B
JavaScript
24 lines
736 B
JavaScript
const temp = require('temp').track();
|
|
const fs = require('fs-plus');
|
|
|
|
describe('keymap-extensions', function() {
|
|
beforeEach(function() {
|
|
atom.keymaps.configDirPath = temp.path('atom-spec-keymap-ext');
|
|
fs.writeFileSync(atom.keymaps.getUserKeymapPath(), '#');
|
|
this.userKeymapLoaded = function() {};
|
|
atom.keymaps.onDidLoadUserKeymap(() => this.userKeymapLoaded());
|
|
});
|
|
|
|
afterEach(function() {
|
|
fs.removeSync(atom.keymaps.configDirPath);
|
|
atom.keymaps.destroy();
|
|
});
|
|
|
|
describe('did-load-user-keymap', () =>
|
|
it('fires when user keymap is loaded', function() {
|
|
spyOn(this, 'userKeymapLoaded');
|
|
atom.keymaps.loadUserKeymap();
|
|
expect(this.userKeymapLoaded).toHaveBeenCalled();
|
|
}));
|
|
});
|