Sha256: 46fe5ca763911fe6020724cea1045f99e3c5d402ead85c842c4f4e9484063484

Contents?: true

Size: 1.75 KB

Versions: 7

Compression:

Stored size: 1.75 KB

Contents

#-*- mode: ruby -*-

begin
  require 'maven/ruby/tasks'
rescue LoadError
  warn "ruby-maven not available - some tasks will not work " <<
       "either `gem install ruby-maven' or use mvn instead of rake"
  desc "Package jopenssl.jar with the compiled classes"
  task :jar do
    sh "mvn prepare-package -Dmaven.test.skip=true"
  end
  namespace :jar do
    desc "Package jopenssl.jar file (and dependendent jars)"
    task :all do
      sh "mvn package -Dmaven.test.skip=true"
    end
  end
else
  Rake::Task[:jar].clear
  desc "Package jopenssl.jar with the compiled classes"
  task :jar => :maven do
    maven.prepare_package '-Dmaven.test.skip=true'
  end
  namespace :jar do
    desc "Package jopenssl.jar file (and dependendent jars)"
    task :all => :maven do
      maven.package '-Dmaven.test.skip=true'
    end
  end
end

# the actual build configuration is inside the Mavenfile

task :default => :build

file('lib/jopenssl.jar') { Rake::Task['jar'].invoke }

require 'rake/testtask'
Rake::TestTask.new do |task|
  task.libs << 'lib'
  task.test_files = FileList['src/test/ruby/**/test*.rb']
  task.verbose = true
  task.loader = :direct
end
task :test => 'lib/jopenssl.jar'

namespace :integration do
  it_path = File.expand_path('../src/test/integration', __FILE__)
  task :install do
    Dir.chdir(it_path) do
      ruby "-S bundle install --gemfile '#{it_path}/Gemfile'"
    end
  end
  # desc "Run IT tests"
  task :test => 'lib/jopenssl.jar' do
    unless File.exist?(File.join(it_path, 'Gemfile.lock'))
      raise "bundle not installed, run `rake integration:install'"
    end
    loader = "ARGV.each { |f| require f }"
    test_files = FileList['src/test/integration/*_test.rb'].to_a
    ruby "-Ilib -e \"#{loader}\" #{test_files.map { |f| "\"#{f}\"" }.join(' ')}"
  end
end

Version data entries

7 entries across 6 versions & 3 rubygems

Version Path
logstash-input-beats-2.0.2 vendor/jruby/1.9/gems/logstash-codec-json-2.0.3/vendor/gems/jruby-openssl-0.9.12-java/Rakefile
logstash-input-beats-2.0.2 vendor/jruby/1.9/gems/jruby-openssl-0.9.12-java/Rakefile
logstash-codec-json-2.0.3 vendor/gems/jruby-openssl-0.9.12-java/Rakefile
logstash-input-beats-0.9.2 vendor/jruby/1.9/gems/jruby-openssl-0.9.12-java/Rakefile
logstash-input-beats-0.9.1 vendor/jruby/1.9/gems/jruby-openssl-0.9.12-java/Rakefile
jruby-openssl-0.9.12-java Rakefile
jruby-openssl-0.9.11-java Rakefile