       cursor [0, 9]
 
     it "applies operators inside the current word in operator-pending mode", ->
-      keystroke 'di<'
-      text().toBe "<>"
-      cursor().toEqual [0, 1]
-      classListContains('operator-pending-mode').toBe(false)
-      classListContains('normal-mode').toBe(true)
+      ensureKeystroke 'di<',
+        text: "<>"
+        cursor: [0, 1]
 
     it "applies operators inside the current word in operator-pending mode (second test)", ->
       cursor [0, 29]
-      keystroke 'di<'
-      text().toBe "< something in here and in <> >"
-      cursor().toEqual [0, 28]
-      classListContains('operator-pending-mode').toBe(false)
-      classListContains('normal-mode').toBe(true)
+      ensureKeystroke 'di<',
+        text: "< something in here and in <> >"
+        cursor: [0, 28]
 
   describe "the 'it' text object", ->
     beforeEach ->

      cursor [0, 9]

    it "applies operators inside the current string in operator-pending mode", ->
      keystroke 'di"'
      text().toBe '""here" " and over here'
      cursor().toEqual [0, 1]
      classListContains('operator-pending-mode').toBe(false)
      classListContains('normal-mode').toBe(true)

    it "[Changed behavior] applies operators inside area between quote", ->
      cursor [0, 29]
      keystroke 'di"'
      text().toBe '" something in here and in "" " and over here'
      cursor().toEqual [0, 28]
      classListContains('operator-pending-mode').toBe(false)
      classListContains('normal-mode').toBe(true)

    it "makes no change if past the last string on a line", ->
      cursor [0, 39]
      keystroke 'di"'
      text().toBe '" something in here and in "here" " and over here'
      cursor().toEqual [0, 39]
      classListContains('operator-pending-mode').toBe(false)

  describe "the 'aw' text object", ->
    beforeEach ->

      cursor [0, 9]

    it "applies operators around the current square brackets in operator-pending mode", ->
      ensureKeystroke 'da[',
        text: ''
        cursor: [0, 0]

    it "applies operators around the current square brackets in operator-pending mode (second test)", ->
      cursor [0, 29]
      ensureKeystroke 'da[',
        text: "[ something in here and in  ]"
        cursor: [0, 27]

  describe "the 'a\'' text object", ->
    beforeEach ->
