<commit_before>'use babel';

describe 'The OpenCL build provider for Atom Linter',  ->
  linter = require('../lib/linter-opencl').provideLinter().lint
  dirPath = __dirname + '/files'

  beforeEach ->
    waitsForPromise ->
      atom.config.set('linter-opencl.pythonPath', '/usr/bin/python')
      atom.config.set('linter-opencl.openCL.platformIndex', 0)
      atom.config.set('linter-opencl.hybridGraphics.enable', true)
      atom.config.set('linter-opencl.hybridGraphics.offloadingPath', '/usr/bin/optirun')
      atom.config.set('linter-opencl.debug', false)
      atom.packages.activatePackage('language-opencl')
      atom.packages.activatePackage('linter-opencl')
      return atom.packages.activatePackage("linter-opencl")

  it 'should be in the packages list', ->
    expect(atom.packages.isPackageLoaded('linter-opencl')).toBe(true)

  it 'should be an active package', ->
    expect(atom.packages.isPackageActive('linter-opencl')).toBe(true)

  it 'find an error in error.cl', ->
    waitsForPromise ->
      filePath = dirPath + '/error.cl'
      expect(filePath).toExistOnDisk()
      return atom.workspace.open(filePath).then (editor) -><commit_msg>"Travis CI (Part 4)"<commit_after>'use babel';

describe 'The OpenCL build provider for Atom Linter',  ->
  linter = require('../lib/linter-opencl').provideLinter().lint
  dirPath = __dirname + '/files'

  beforeEach ->
    waitsForPromise ->
      atom.config.set('linter-opencl.pythonPath', '/usr/bin/python')
      atom.config.set('linter-opencl.openCL.platformIndex', 0)
      atom.config.set('linter-opencl.hybridGraphics.enable', false)
      atom.config.set('linter-opencl.hybridGraphics.offloadingPath', '/usr/bin/optirun')
      atom.config.set('linter-opencl.debug', false)
      atom.packages.activatePackage('language-opencl')
      atom.packages.activatePackage('linter-opencl')
      return atom.packages.activatePackage("linter-opencl")

  it 'should be in the packages list', ->
    expect(atom.packages.isPackageLoaded('linter-opencl')).toBe(true)

  it 'should be an active package', ->
    expect(atom.packages.isPackageActive('linter-opencl')).toBe(true)

  it 'find an error in error.cl', ->
    waitsForPromise ->
      filePath = dirPath + '/error.cl'
      expect(filePath).toExistOnDisk()
      return atom.workspace.open(filePath).then (editor) ->
{'fraction_non_alphanumeric': 0.1514114627887083, 'fraction_numerical': 0.0012831479897348161, 'mean_word_length': 3.8127572016460904, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 19, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1531109', 'n_tokens_mistral': 755, 'n_tokens_neox': 739, 'n_words': 123}