Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
activeadmin / spec / requests / javascript_spec.rb
Size: Mime:
require 'rails_helper'
require 'jslint'

%x[which java]
if $? == 0 # Only run the JS Lint test if Java is installed
  describe "Javascript", :type => :request do
    before do
      @lint = JSLint::Lint.new(
        paths: ['public/javascripts/**/*.js'],
        exclude_paths: ['public/javascripts/vendor/**/*.js'],
        config_path: 'spec/support/jslint.yml'
      )
    end

    it "should not have any syntax errors" do
      @lint.run
    end
  end
end