           top: 10
           height: 20
           class: 'test-class-2'
-      customGutterComponent.updateSync(buildTestState(changedCustomDecorations))
-      changedDecorationNode = customGutterComponent.getDomNode().children.item(0).children.item(0)
+      gutterComponent.updateSync(buildTestState(changedCustomDecorations))
+      changedDecorationNode = gutterComponent.getDomNode().children.item(0).children.item(0)
       expect(changedDecorationNode).toBe initialDecorationNode
       expect(changedDecorationNode.style.top).toBe '10px'
       expect(changedDecorationNode.style.height).toBe '20px'

      mockTestState

    it "sets the custom-decoration wrapper's scrollHeight, scrollTop, and background color", ->
      decorationsWrapperNode = customGutterComponent.getDomNode().children.item(0)
      expect(decorationsWrapperNode.style.height).toBe ''
      expect(decorationsWrapperNode.style['-webkit-transform']).toBe ''
      expect(decorationsWrapperNode.style.backgroundColor).toBe ''

      customGutterComponent.updateSync(buildTestState({}))
      expect(decorationsWrapperNode.style.height).not.toBe ''
      expect(decorationsWrapperNode.style['-webkit-transform']).not.toBe ''
      expect(decorationsWrapperNode.style.backgroundColor).not.toBe ''

Gutter = require '../src/gutter'

describe "CustomGutterComponent", ->
  [gutterComponent, gutter] = []

  beforeEach ->
    mockGutterContainer = {}
    gutter = new Gutter(mockGutterContainer, {name: 'test-gutter'})
    gutterComponent = new CustomGutterComponent({gutter})

  it "creates a gutter DOM node with only an empty 'custom-decorations' child node when it is initialized", ->
    expect(gutterComponent.getDomNode().classList.contains('gutter')).toBe true
    expect(gutterComponent.getDomNode().getAttribute('gutter-name')).toBe 'test-gutter'
    expect(gutterComponent.getDomNode().children.length).toBe 1
    decorationsWrapperNode = gutterComponent.getDomNode().children.item(0)
    expect(decorationsWrapperNode.classList.contains('custom-decorations')).toBe true

  it "makes its view accessible from the view registry", ->
    expect(gutterComponent.getDomNode()).toBe atom.views.getView(gutter)

  it "hides its DOM node when ::hideNode is called, and shows its DOM node when ::showNode is called", ->
    gutterComponent.hideNode()
    expect(gutterComponent.getDomNode().style.display).toBe 'none'
    gutterComponent.showNode()
    expect(gutterComponent.getDomNode().style.display).toBe ''

  describe "::updateSync", ->
    decorationItem1 = document.createElement('div')
