+_ = require 'underscore-plus'
 path = require 'path'
-_ = require 'underscore-plus'
-{$} = require 'atom-space-pen-views'
 temp = require "temp"
-
 ResultsPaneView = require '../lib/project/results-pane'
 FileIcons = require '../lib/file-icons'
 

        expect(fileIconClasses).not.toContain('third-icon-class fourth-icon-class icon')
        expect(fileIconClasses).toContain('icon-file-text icon')

  # Keep. Useful for debugging.
  logSelectedIndex = ->
    paths = resultsView.find('.path')
    selectedView = resultsView.find('.selected')

    if selectedView.hasClass('path')
      console.log 'PATH', paths.index(selectedView)
    else
      for pathElement, pathIndex in paths
        index = $(pathElement).find('.search-result').index(selectedView)
        console.log pathIndex, index if index > -1
        break

buildMouseEvent = (type, properties...) ->
  properties = _.extend({bubbles: true, cancelable: true}, properties...)
  properties.detail ?= 1
  event = new MouseEvent(type, properties)
  Object.defineProperty(event, 'which', get: -> properties.which) if properties.which?
  if properties.target?

    atom.commands.dispatch workspaceElement, 'project-find:show'

    waitsForPromise ->
      activationPromise

  describe "result sorting", ->
    beforeEach ->
