 
     describe "when the editor.showIndentGuide config setting changes", ->
       it "updates .indentGuidesVisible", ->
-        presenter = new TextEditorPresenter(model: editor, clientHeight: 25, clientWidth: 50, scrollTop: 0, baseCharacterWidth: 10, lineHeight: 10, lineOverdrawMargin: 0)
+        presenter = new TextEditorPresenter(model: editor)
         expect(presenter.state.content.indentGuidesVisible).toBe false
 
         atom.config.set('editor.showIndentGuide', true)

      it "assigns .scrollWidth based on the clientWidth and the width of the longest line", ->
        maxLineLength = editor.getMaxScreenLineLength()

        presenter = new TextEditorPresenter(model: editor, clientHeight: 25, clientWidth: 50, scrollTop: 0, baseCharacterWidth: 10, lineHeight: 10, lineOverdrawMargin: 0)
        expect(presenter.state.content.scrollWidth).toBe 10 * maxLineLength + 1

        presenter = new TextEditorPresenter(model: editor, clientHeight: 25, clientWidth: 10 * maxLineLength + 20, scrollTop: 0, baseCharacterWidth: 10, lineHeight: 10, lineOverdrawMargin: 0)
        expect(presenter.state.content.scrollWidth).toBe 10 * maxLineLength + 20

      it "assigns .indentGuidesVisible based on the editor.showIndentGuide config setting", ->
        presenter = new TextEditorPresenter(model: editor, clientHeight: 25, clientWidth: 50, scrollTop: 0, baseCharacterWidth: 10, lineHeight: 10, lineOverdrawMargin: 0)
        expect(presenter.state.content.indentGuidesVisible).toBe false

        atom.config.set('editor.showIndentGuide', true)
        presenter = new TextEditorPresenter(model: editor, clientHeight: 25, clientWidth: 50, scrollTop: 0, baseCharacterWidth: 10, lineHeight: 10, lineOverdrawMargin: 0)
        expect(presenter.state.content.indentGuidesVisible).toBe true

    describe "when the ::clientWidth changes", ->
      it "updates .scrollWidth", ->
        maxLineLength = editor.getMaxScreenLineLength()
        presenter = new TextEditorPresenter(model: editor, clientHeight: 25, clientWidth: 50, scrollTop: 0, scrollWidth: 70, lineHeight: 10, baseCharacterWidth: 10, lineOverdrawMargin: 0)

        expect(presenter.state.content.scrollWidth).toBe 10 * maxLineLength + 1
        presenter.setClientWidth(10 * maxLineLength + 20)


      it "updates the width of the lines if the ::scrollWidth changes", ->
        maxLineLength = editor.getMaxScreenLineLength()
        presenter = new TextEditorPresenter(model: editor, clientWidth: 50, baseCharacterWidth: 10)

        expect(presenter.state.content.scrollWidth).toBe 10 * maxLineLength + 1
        presenter.setScopedCharWidth(['source.js', 'support.function.js'], 'p', 20)
