     it "places the wrap guide at the custom column", ->
       atom.config.set('wrap-guide.columns', [{pattern: '\.js$', column: 20}])
       wrapGuide.updateGuide()
-      width = editorView.charWidth * 20
+      width = editor.getDefaultCharWidth() * 20
       expect(width).toBeGreaterThan(0)
       expect($(wrapGuide).position().left).toBe(width)
 
     it "uses the default column when no custom column matches the path", ->
       atom.config.set('wrap-guide.columns', [{pattern: '\.jsp$', column: '100'}])
       wrapGuide.updateGuide()
-      width = editorView.charWidth * wrapGuide.getDefaultColumn()
+      width = editor.getDefaultCharWidth() * wrapGuide.getDefaultColumn()
       expect(width).toBeGreaterThan(0)
       expect($(wrapGuide).position().left).toBe(width)
 

    it "places the wrap guide at the custom column using scope name", ->
      atom.config.set('wrap-guide.columns', [{scope: 'source.js', column: 20}])
      wrapGuide.updateGuide()
      width = editorView.charWidth * 20
      expect(width).toBeGreaterThan(0)
      expect($(wrapGuide).position().left).toBe(width)

    it "uses the default column when no scope name matches", ->
      atom.config.set('wrap-guide.columns', [{scope: 'source.gfm', column: '100'}])
      wrapGuide.updateGuide()
      width = editorView.charWidth * wrapGuide.getDefaultColumn()
      expect(width).toBeGreaterThan(0)
      expect($(wrapGuide).position().left).toBe(width)



    runs ->
      editor = atom.workspace.getActiveTextEditor()
      wrapGuide = workspaceElement.querySelector(".wrap-guide")

  describe ".activate", ->
