message: Test black hole register delete remappings
diff: @@ -7,12 +7,15 @@ import { ModeHandler } from '../../src/mode/modeHandler';
  import { Configuration } from '../testConfiguration';
  import { assertEqual, setupWorkspace, cleanUpWorkspace } from '../testUtils';
  import { IKeyRemapping } from '../../src/configuration/iconfiguration';
  +import { IRegisterContent, Register } from '../../src/register/register';
  import { getAndUpdateModeHandler } from '../../extension';
  +import { VimState } from '../../src/state/vimState';
  /* tslint:disable:no-string-literal */
  suite('Remapper', () => {
  let modeHandler: ModeHandler;
  + let vimState: VimState;
  const leaderKey = '\\';
  const insertModeKeyBindings: IKeyRemapping[] = [
  {
  @@ -39,6 +42,10 @@ suite('Remapper', () => {
  },
  ],
  },
  + {
  + before: ['d'],
  + after: ['"', '_', 'd'],
  + },
  ];
  const visualModeKeyBindings: IKeyRemapping[] = [
  {
  @@ -81,6 +88,7 @@ suite('Remapper', () => {
  await setupWorkspace(configuration);
  modeHandler = await getAndUpdateModeHandler();
  + vimState = modeHandler.vimState;
  });
  teardown(cleanUpWorkspace);
  @@ -271,6 +279,24 @@ suite('Remapper', () => {
  assert.equal(actual, true);
  assert.equal(vscode.window.visibleTextEditors.length, 0);
  });
  +
  + test('d -> black hole register delete in normal mode through modehandler', async () => {
  + assert.equal(modeHandler.currentMode.name, ModeName.Normal);
  +
  + await modeHandler.handleMultipleKeyEvents(['<Esc>', 'g', 'g']);
  + await modeHandler.handleMultipleKeyEvents(['i', 'line1', '<Esc>']);
  +
  + const expected = 'text-to-put-on-register';
  + let actual: IRegisterContent;
  + Register.put(expected, modeHandler.vimState);
  + actual = await Register.get(vimState);
  + assert.equal(actual.text, expected);
  +
  + await modeHandler.handleMultipleKeyEvents(['d', 'd']);
  +
  + actual = await Register.get(vimState);
  + assert.equal(actual.text, expected);
  + });
  });
  /* tslint:enable:no-string-literal */
  