Sha256: 42cd1706e8f2a9f5e0fa09e07af5e246aa25a2abb0bfa6e80cf405f8992b6e3d

Contents?: true

Size: 829 Bytes

Versions: 16

Compression:

Stored size: 829 Bytes

Contents

Given(/^I have an app with license finder that depends on a GPL licensed gem$/) do
  @user = ::DSL::User.new
  @user.create_nonrails_app
  @user.add_dependency_to_app "gpl_gem", :license => "GPL"
end

When(/^I approve that gem$/) do
  @output = @user.execute_command "license_finder"
  @output.should include "gpl_gem"
  @output = @user.execute_command "license_finder approve gpl_gem"
  @output = @user.execute_command "license_finder --quiet"
end

Then(/^I should not see that gem in the console output$/) do
  @output.should_not include "gpl_gem"
end

Then(/^I should see that gem approved in dependencies\.html$/) do
  gem_name = "gpl_gem"
  css_class = "approved"
  html = File.read(@user.dependencies_html_path)
  page = Capybara.string(html)
  gpl_gem = page.find("##{gem_name}")
  gpl_gem[:class].should == css_class
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
license_finder-1.0.0.0 features/step_definitions/approve_dependencies_steps.rb
license_finder-1.0.0.0-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.5.1-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.5.1 features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.5 features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.5-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.4-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.4 features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.3-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.3 features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.2-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.2 features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.1-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.1 features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.0-java features/step_definitions/approve_dependencies_steps.rb
license_finder-0.9.0 features/step_definitions/approve_dependencies_steps.rb