license_finder 1.2 → 2.0.0.rc2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (220) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +2 -1
  3. data/CHANGELOG.rdoc +27 -0
  4. data/CONTRIBUTING.md +38 -0
  5. data/README.md +139 -159
  6. data/Rakefile +17 -13
  7. data/features/features/cli_spec.rb +43 -0
  8. data/features/features/configure/add_dependencies_spec.rb +37 -0
  9. data/features/features/configure/approve_dependencies_spec.rb +30 -0
  10. data/features/features/configure/assign_licenses_spec.rb +20 -0
  11. data/features/features/configure/ignore_dependencies_spec.rb +35 -0
  12. data/features/features/configure/ignore_groups_spec.rb +31 -0
  13. data/features/features/configure/name_project_spec.rb +32 -0
  14. data/features/features/configure/whitelist_licenses_spec.rb +40 -0
  15. data/features/features/package_managers/bower_spec.rb +14 -0
  16. data/features/features/package_managers/cocoapods_spec.rb +14 -0
  17. data/features/features/package_managers/gradle_spec.rb +14 -0
  18. data/features/features/package_managers/maven_spec.rb +14 -0
  19. data/features/features/package_managers/npm_spec.rb +14 -0
  20. data/features/features/package_managers/pip_spec.rb +14 -0
  21. data/features/features/report/csv_spec.rb +17 -0
  22. data/features/features/report/html_spec.rb +50 -0
  23. data/{spec → features}/fixtures/Podfile +0 -0
  24. data/{spec → features}/fixtures/build.gradle +0 -0
  25. data/{spec → features}/fixtures/pom.xml +0 -0
  26. data/features/support/testing_dsl.rb +295 -0
  27. data/lib/license_finder.rb +16 -50
  28. data/lib/license_finder/cli.rb +13 -253
  29. data/lib/license_finder/cli/approvals.rb +26 -0
  30. data/lib/license_finder/cli/base.rb +20 -0
  31. data/lib/license_finder/cli/dependencies.rb +39 -0
  32. data/lib/license_finder/cli/ignored_dependencies.rb +30 -0
  33. data/lib/license_finder/cli/ignored_groups.rb +30 -0
  34. data/lib/license_finder/cli/licenses.rb +24 -0
  35. data/lib/license_finder/cli/main.rb +82 -0
  36. data/lib/license_finder/cli/makes_decisions.rb +48 -0
  37. data/lib/license_finder/cli/patched_thor.rb +34 -0
  38. data/lib/license_finder/cli/project_name.rb +31 -0
  39. data/lib/license_finder/cli/whitelist.rb +32 -0
  40. data/lib/license_finder/configuration.rb +14 -145
  41. data/lib/license_finder/decision_applier.rb +46 -0
  42. data/lib/license_finder/decisions.rb +174 -0
  43. data/lib/license_finder/license.rb +13 -32
  44. data/lib/license_finder/license/definitions.rb +15 -13
  45. data/lib/license_finder/license/template.rb +1 -1
  46. data/lib/{data/licenses → license_finder/license/templates}/Apache2.txt +0 -0
  47. data/lib/{data/licenses → license_finder/license/templates}/BSD.txt +0 -0
  48. data/lib/{data/licenses → license_finder/license/templates}/GPLv2.txt +0 -0
  49. data/lib/{data/licenses → license_finder/license/templates}/ISC.txt +0 -0
  50. data/lib/{data/licenses → license_finder/license/templates}/LGPL.txt +0 -0
  51. data/lib/{data/licenses → license_finder/license/templates}/MIT.txt +0 -0
  52. data/lib/{data/licenses → license_finder/license/templates}/NewBSD.txt +0 -0
  53. data/lib/{data/licenses → license_finder/license/templates}/Python.txt +0 -0
  54. data/lib/{data/licenses → license_finder/license/templates}/Ruby.txt +0 -0
  55. data/lib/{data/licenses → license_finder/license/templates}/SimplifiedBSD.txt +0 -0
  56. data/lib/license_finder/package.rb +77 -7
  57. data/lib/license_finder/package_manager.rb +43 -0
  58. data/lib/license_finder/package_managers/bower.rb +1 -1
  59. data/lib/license_finder/package_managers/bower_package.rb +23 -44
  60. data/lib/license_finder/package_managers/bundler.rb +4 -7
  61. data/lib/license_finder/package_managers/bundler_package.rb +14 -31
  62. data/lib/license_finder/package_managers/cocoa_pods.rb +1 -1
  63. data/lib/license_finder/package_managers/cocoa_pods_package.rb +2 -10
  64. data/lib/license_finder/package_managers/gradle.rb +6 -2
  65. data/lib/license_finder/package_managers/gradle_package.rb +6 -30
  66. data/lib/license_finder/package_managers/manual_package.rb +25 -0
  67. data/lib/license_finder/package_managers/maven_package.rb +8 -37
  68. data/lib/license_finder/package_managers/npm.rb +16 -4
  69. data/lib/license_finder/package_managers/npm_package.rb +12 -43
  70. data/lib/license_finder/package_managers/pip_package.rb +17 -37
  71. data/lib/license_finder/platform.rb +0 -16
  72. data/lib/license_finder/possible_license_file.rb +9 -14
  73. data/lib/license_finder/possible_license_files.rb +1 -5
  74. data/lib/license_finder/report.rb +26 -0
  75. data/lib/license_finder/reports/csv_report.rb +58 -0
  76. data/lib/license_finder/reports/erb_report.rb +61 -0
  77. data/lib/license_finder/reports/html_report.rb +10 -1
  78. data/lib/license_finder/reports/markdown_report.rb +7 -1
  79. data/lib/license_finder/reports/templates/bootstrap.css +9 -0
  80. data/lib/license_finder/reports/templates/html_report.erb +105 -0
  81. data/lib/{templates → license_finder/reports/templates}/markdown_report.erb +7 -7
  82. data/lib/license_finder/reports/text_report.rb +5 -3
  83. data/lib/license_finder/version.rb +3 -0
  84. data/license_finder.gemspec +2 -6
  85. data/release/instructions.md +8 -0
  86. data/spec/feature_helper.rb +11 -0
  87. data/spec/fixtures/config/license_finder.yml +3 -0
  88. data/spec/fixtures/{nested_readme/vendor/README → license_directory/LICENSE/Apache.txt} +0 -0
  89. data/spec/lib/license_finder/cli/approvals_spec.rb +63 -0
  90. data/spec/lib/license_finder/cli/dependencies_spec.rb +59 -0
  91. data/spec/lib/license_finder/cli/ignored_dependencies_spec.rb +47 -0
  92. data/spec/lib/license_finder/cli/ignored_groups_spec.rb +40 -0
  93. data/spec/lib/license_finder/cli/licenses_spec.rb +60 -0
  94. data/spec/lib/license_finder/cli/main_spec.rb +110 -0
  95. data/spec/lib/license_finder/cli/project_name_spec.rb +40 -0
  96. data/spec/lib/license_finder/cli/whitelist_spec.rb +58 -0
  97. data/spec/lib/license_finder/configuration_spec.rb +46 -191
  98. data/spec/lib/license_finder/decision_applier_spec.rb +65 -0
  99. data/spec/lib/license_finder/decisions_spec.rb +347 -0
  100. data/spec/lib/license_finder/license/definitions_spec.rb +1 -7
  101. data/spec/lib/license_finder/license_spec.rb +2 -30
  102. data/spec/lib/license_finder/package_manager_spec.rb +22 -0
  103. data/spec/lib/license_finder/package_managers/bower_package_spec.rb +33 -66
  104. data/spec/lib/license_finder/package_managers/bundler_package_spec.rb +7 -71
  105. data/spec/lib/license_finder/package_managers/cocoa_pods_package_spec.rb +8 -11
  106. data/spec/lib/license_finder/package_managers/gradle_package_spec.rb +28 -32
  107. data/spec/lib/license_finder/package_managers/gradle_spec.rb +18 -23
  108. data/spec/lib/license_finder/package_managers/maven_package_spec.rb +20 -43
  109. data/spec/lib/license_finder/package_managers/npm_package_spec.rb +22 -73
  110. data/spec/lib/license_finder/package_managers/npm_spec.rb +18 -21
  111. data/spec/lib/license_finder/package_managers/pip_package_spec.rb +24 -63
  112. data/spec/lib/license_finder/package_spec.rb +121 -0
  113. data/spec/lib/license_finder/possible_license_file_spec.rb +2 -3
  114. data/spec/lib/license_finder/possible_license_files_spec.rb +18 -22
  115. data/spec/lib/license_finder/reports/csv_report_spec.rb +26 -0
  116. data/spec/lib/license_finder/reports/html_report_spec.rb +39 -22
  117. data/spec/lib/license_finder/reports/markdown_report_spec.rb +8 -16
  118. data/spec/lib/license_finder/reports/text_report_spec.rb +21 -12
  119. data/spec/spec_helper.rb +1 -4
  120. data/spec/support/shared_examples_for_package.rb +0 -11
  121. data/spec/support/shared_examples_for_package_manager.rb +1 -0
  122. data/spec/support/stdout_helpers.rb +4 -11
  123. metadata +73 -158
  124. data/db/migrate/201303290935_create_dependencies.rb +0 -14
  125. data/db/migrate/201303291155_create_licenses.rb +0 -13
  126. data/db/migrate/201303291402_create_approvals.rb +0 -13
  127. data/db/migrate/201303291456_create_ancestries.rb +0 -9
  128. data/db/migrate/201303291519_create_bundler_groups.rb +0 -13
  129. data/db/migrate/201303291720_move_manual_from_approvals_to_licenses.rb +0 -11
  130. data/db/migrate/201303291753_allow_null_license_names.rb +0 -7
  131. data/db/migrate/201304011027_allow_null_dependency_version.rb +0 -7
  132. data/db/migrate/201304020947_change_table_name_licenses_to_license_aliases.rb +0 -5
  133. data/db/migrate/201304181524_add_manual_to_dependencies.rb +0 -7
  134. data/db/migrate/201307250917_add_license_manual_to_dependencies.rb +0 -7
  135. data/db/migrate/201307251004_data_fix_manual_licenses.rb +0 -15
  136. data/db/migrate/201307251107_reassociate_license.rb +0 -23
  137. data/db/migrate/201307251340_remove_manual_from_license_aliases.rb +0 -7
  138. data/db/migrate/201311192002_add_manually_approved_to_dependencies.rb +0 -7
  139. data/db/migrate/201311192003_reassociate_manual_approval.rb +0 -13
  140. data/db/migrate/201311192010_drop_approvals.rb +0 -5
  141. data/db/migrate/201401302113_re_reassociate_license.rb +0 -23
  142. data/db/migrate/201403181732_rename_manual_fields.rb +0 -10
  143. data/db/migrate/201403190028_add_manual_approvals.rb +0 -22
  144. data/db/migrate/201403191419_add_timestamps_to_manual_approvals.rb +0 -15
  145. data/db/migrate/201403191645_remove_license_aliases.rb +0 -23
  146. data/db/migrate/201410031451_rename_dependency_license_name.rb +0 -6
  147. data/features/cli.feature +0 -37
  148. data/features/cocoapods_dependencies.feature +0 -10
  149. data/features/configure_bundler_groups.feature +0 -23
  150. data/features/configure_ignore_dependencies.feature +0 -16
  151. data/features/configure_project_name.feature +0 -10
  152. data/features/configure_whitelist.feature +0 -27
  153. data/features/gradle_dependencies.feature +0 -9
  154. data/features/manually_added.feature +0 -19
  155. data/features/manually_approved.feature +0 -10
  156. data/features/manually_assigned_license.feature +0 -16
  157. data/features/maven_dependencies.feature +0 -9
  158. data/features/multiple_licenses.feature +0 -9
  159. data/features/node_dependencies.feature +0 -9
  160. data/features/python_dependencies.feature +0 -9
  161. data/features/report_csv.feature +0 -15
  162. data/features/report_html.feature +0 -24
  163. data/features/step_definitions/cli_steps.rb +0 -51
  164. data/features/step_definitions/cocoapod_steps.rb +0 -8
  165. data/features/step_definitions/configure_bundler_groups_steps.rb +0 -30
  166. data/features/step_definitions/configure_ignore_dependencies.rb +0 -35
  167. data/features/step_definitions/configure_project_name_steps.rb +0 -3
  168. data/features/step_definitions/configure_whitelist_steps.rb +0 -45
  169. data/features/step_definitions/gradle_steps.rb +0 -8
  170. data/features/step_definitions/manually_added_steps.rb +0 -28
  171. data/features/step_definitions/manually_approved_steps.rb +0 -24
  172. data/features/step_definitions/manually_assigned_license_steps.rb +0 -34
  173. data/features/step_definitions/maven_steps.rb +0 -8
  174. data/features/step_definitions/multiple_licenses_steps.rb +0 -14
  175. data/features/step_definitions/node_steps.rb +0 -8
  176. data/features/step_definitions/python_steps.rb +0 -8
  177. data/features/step_definitions/report_csv_steps.rb +0 -20
  178. data/features/step_definitions/report_html_steps.rb +0 -60
  179. data/features/step_definitions/shared_steps.rb +0 -307
  180. data/lib/data/license_finder.example.yml +0 -12
  181. data/lib/license_finder/dependency_manager.rb +0 -92
  182. data/lib/license_finder/package_saver.rb +0 -44
  183. data/lib/license_finder/reports/dependency_report.rb +0 -34
  184. data/lib/license_finder/reports/detailed_text_report.rb +0 -19
  185. data/lib/license_finder/reports/formatted_report.rb +0 -40
  186. data/lib/license_finder/reports/reporter.rb +0 -27
  187. data/lib/license_finder/tables.rb +0 -9
  188. data/lib/license_finder/tables/bundler_group.rb +0 -7
  189. data/lib/license_finder/tables/dependency.rb +0 -113
  190. data/lib/license_finder/tables/manual_approval.rb +0 -13
  191. data/lib/license_finder/yml_to_sql.rb +0 -117
  192. data/lib/templates/html_report.erb +0 -117
  193. data/lib/templates/text_report.erb +0 -3
  194. data/release/gem_version.rb +0 -3
  195. data/release/manual_instructions.md +0 -29
  196. data/release/publish.sh +0 -32
  197. data/spec/fixtures/APACHE-2-LICENSE +0 -202
  198. data/spec/fixtures/GPLv2 +0 -339
  199. data/spec/fixtures/ISC-LICENSE +0 -10
  200. data/spec/fixtures/MIT-LICENSE +0 -22
  201. data/spec/fixtures/MIT-LICENSE-with-varied-disclaimer +0 -22
  202. data/spec/fixtures/README-with-MIT-LICENSE +0 -222
  203. data/spec/fixtures/license_directory/LICENSE/BSD-2-Clause.txt +0 -25
  204. data/spec/fixtures/license_directory/LICENSE/GPL-2.0.txt +0 -339
  205. data/spec/fixtures/license_directory/LICENSE/LICENSE +0 -191
  206. data/spec/fixtures/license_directory/LICENSE/MIT.txt +0 -21
  207. data/spec/fixtures/license_directory/LICENSE/RUBY.txt +0 -60
  208. data/spec/fixtures/mit_licensed_gem/LICENSE +0 -22
  209. data/spec/fixtures/other_licensed_gem/LICENSE +0 -3
  210. data/spec/fixtures/readme/Project ReadMe b/data/spec/fixtures/readme/Project → ReadMe +0 -0
  211. data/spec/fixtures/readme/README +0 -0
  212. data/spec/fixtures/readme/Readme.markdown +0 -0
  213. data/spec/lib/license_finder/cli_spec.rb +0 -298
  214. data/spec/lib/license_finder/dependency_manager_spec.rb +0 -198
  215. data/spec/lib/license_finder/package_saver_spec.rb +0 -82
  216. data/spec/lib/license_finder/reports/detailed_text_report_spec.rb +0 -33
  217. data/spec/lib/license_finder/reports/reporter_spec.rb +0 -33
  218. data/spec/lib/license_finder/tables/dependency_spec.rb +0 -196
  219. data/spec/lib/license_finder/yml_to_sql_spec.rb +0 -123
  220. data/spec/lib/license_finder_spec.rb +0 -16
@@ -1,11 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:approvals) do
4
- drop_column :approval_type
5
- end
6
-
7
- alter_table(:licenses) do
8
- add_column :manual, TrueClass # i.e., keep this license eternally
9
- end
10
- end
11
- end
@@ -1,7 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:licenses) do
4
- set_column_allow_null :name
5
- end
6
- end
7
- end
@@ -1,7 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:dependencies) do
4
- set_column_allow_null :version
5
- end
6
- end
7
- end
@@ -1,5 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- rename_table(:licenses, :license_aliases)
4
- end
5
- end
@@ -1,7 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:dependencies) do
4
- add_column :manual, TrueClass # i.e., keep this dependency eternally
5
- end
6
- end
7
- end
@@ -1,7 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:dependencies) do
4
- add_column :license_manual, TrueClass
5
- end
6
- end
7
- end
@@ -1,15 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- LicenseFinder::DB << <<-SQL
4
- UPDATE dependencies
5
- SET license_manual = 1
6
- WHERE id
7
- IN
8
- (SELECT d.id
9
- FROM dependencies d
10
- INNER JOIN license_aliases l
11
- ON d.license_id = l.id
12
- WHERE l.manual = 1)
13
- SQL
14
- end
15
- end
@@ -1,23 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- LicenseFinder::DB << <<-SQL
4
- UPDATE dependencies
5
- SET license_id =
6
- (SELECT la.id
7
- FROM
8
- license_aliases la,
9
- license_aliases la_orig
10
- WHERE
11
- la.name = la_orig.name AND
12
- la_orig.id = license_id
13
- LIMIT 1)
14
- SQL
15
-
16
- LicenseFinder::DB << <<-SQL
17
- DELETE
18
- FROM license_aliases
19
- WHERE
20
- id NOT IN (SELECT license_id FROM dependencies)
21
- SQL
22
- end
23
- end
@@ -1,7 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:license_aliases) do
4
- drop_column :manual
5
- end
6
- end
7
- end
@@ -1,7 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:dependencies) do
4
- add_column :manually_approved, TrueClass
5
- end
6
- end
7
- end
@@ -1,13 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- LicenseFinder::DB << <<-EOS
4
- UPDATE dependencies
5
- SET manually_approved =
6
- (SELECT state
7
- FROM
8
- approvals
9
- WHERE
10
- approvals.id = dependencies.approval_id)
11
- EOS
12
- end
13
- end
@@ -1,5 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- drop_table(:approvals)
4
- end
5
- end
@@ -1,23 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- LicenseFinder::DB << <<-SQL
4
- UPDATE dependencies
5
- SET license_id =
6
- (SELECT min(la.id)
7
- FROM
8
- license_aliases la,
9
- license_aliases la_orig
10
- WHERE
11
- la.name = la_orig.name AND
12
- la_orig.id = license_id
13
- LIMIT 1)
14
- SQL
15
-
16
- LicenseFinder::DB << <<-SQL
17
- DELETE
18
- FROM license_aliases
19
- WHERE
20
- id NOT IN (SELECT license_id FROM dependencies)
21
- SQL
22
- end
23
- end
@@ -1,10 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- alter_table(:dependencies) do
4
- rename_column :manual, :added_manually
5
- rename_column :manually_approved, :approved_manually
6
- rename_column :license_manual, :license_assigned_manually
7
- drop_column :approval_id
8
- end
9
- end
10
- end
@@ -1,22 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- create_table(:manual_approvals) do
4
- primary_key :id
5
- foreign_key :dependency_id, :dependencies, unique: true, on_delete: :cascade
6
- String :approver, null: true
7
- String :notes, null: true
8
- end
9
-
10
- LicenseFinder::DB << <<-SQL
11
- INSERT INTO manual_approvals
12
- (dependency_id)
13
- SELECT id
14
- FROM dependencies
15
- WHERE approved_manually;
16
- SQL
17
-
18
- alter_table(:dependencies) do
19
- drop_column :approved_manually
20
- end
21
- end
22
- end
@@ -1,15 +0,0 @@
1
- Sequel.migration do
2
- change do
3
- alter_table(:manual_approvals) do
4
- add_column :created_at, DateTime
5
- add_column :updated_at, DateTime
6
- end
7
-
8
- LicenseFinder::DB << <<-SQL
9
- UPDATE manual_approvals
10
- SET
11
- created_at = datetime('now'),
12
- updated_at = datetime('now')
13
- SQL
14
- end
15
- end
@@ -1,23 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- alter_table(:dependencies) do
4
- add_column :license_name, String
5
- end
6
-
7
- LicenseFinder::DB << <<-SQL
8
- UPDATE dependencies
9
- SET license_name =
10
- (SELECT name
11
- FROM
12
- license_aliases
13
- WHERE
14
- license_id = license_aliases.id)
15
- SQL
16
-
17
- alter_table(:dependencies) do
18
- drop_column :license_id
19
- end
20
-
21
- drop_table(:license_aliases)
22
- end
23
- end
@@ -1,6 +0,0 @@
1
- Sequel.migration do
2
- up do
3
- rename_column :dependencies, :license_name, :license_names
4
- run %Q{UPDATE dependencies SET license_names='["' || license_names || '"]'}
5
- end
6
- end
data/features/cli.feature DELETED
@@ -1,37 +0,0 @@
1
- Feature: License Finder command line executable
2
- So that I can manage my application's dependencies and licenses
3
- As an application developer
4
- I want a command-line interface
5
-
6
- Scenario: Auditing an application with unapproved licenses
7
- Given I have an app with an unapproved dependency
8
- When I run license_finder
9
- Then it should exit with status code 1
10
- And should list my unapproved dependency in the output
11
-
12
- Scenario: Auditing an application with approved licenses
13
- Given I have an app with an unapproved dependency
14
- When I whitelist everything I can think of
15
- Then it should exit with status code 0
16
- And I should see all dependencies approved for use
17
-
18
- Scenario: Viewing help for license_finder subcommand
19
- Given I have an app
20
- When I run license_finder help on a specific command
21
- Then I should see the correct subcommand usage instructions
22
-
23
- Scenario: Viewing help for license_finder default
24
- Given I have an app
25
- When I run license_finder help
26
- Then I should see the default usage instructions
27
-
28
- Scenario: Running without a configuration file
29
- Given I have an app that has no config directory
30
- When I run license_finder
31
- Then it creates a config directory with the license_finder config
32
-
33
- Scenario: Viewing License Finder's own license
34
- Given I have an app
35
- When I run license_finder
36
- Then I should see License Finder has the MIT license
37
-
@@ -1,10 +0,0 @@
1
- @ios
2
- Feature: Tracking CocoaPods Dependencies
3
- So that I can track CocoaPods dependencies
4
- As an application developer using license finder
5
- I want to be able to manage CocoaPods dependencies
6
-
7
- Scenario: See the dependencies from the Podfile
8
- Given A Podfile with dependencies
9
- When I run license_finder
10
- Then I should see a CocoaPods dependency with a license
@@ -1,23 +0,0 @@
1
- Feature: Ignore Bundle Groups
2
- As a developer
3
- I want to ignore certain bundler groups
4
- So that any gems I use in development, or for testing, are automatically approved for use
5
-
6
- Scenario: Bundler groups can be ignored
7
- Given I have an app
8
- And I ignore the test group
9
- When I get the ignored groups
10
- Then I should see the test group in the output
11
-
12
- Scenario: Ignored bundler groups are not evaluated for licenses
13
- Given I have an app that depends on a gem in the test bundler group
14
- And I ignore the test group
15
- When I run license_finder
16
- Then I should not see the test gem in the output
17
-
18
- Scenario: Bundler groups can be removed from the ignore list
19
- Given I have an app
20
- And I ignore the test group
21
- And I stop ignoring the test group
22
- When I get the ignored groups
23
- Then I should not see the test group in the output
@@ -1,16 +0,0 @@
1
- Feature: Ignore Dependencies
2
- As a developer
3
- I want to ignore certain dependencies
4
- To avoid noisy doc changes when there are safe dependencies with high version churn
5
-
6
- Scenario: Select dependencies can be ignored
7
- Given I have an app that depends on bundler
8
- And I ignore the bundler dependency
9
- When I get the ignored dependencies
10
- Then I should see 'bundler' in the output
11
- And I should not see 'bundler' in the dependency docs
12
-
13
- Scenario: Ignored dependencies do not appear in the unapproved list
14
- Given I have an app that depends on bundler
15
- When I ignore the bundler dependency
16
- Then the bundler dependency is not listed as an action item
@@ -1,10 +0,0 @@
1
- Feature: Project names
2
- As a developer
3
- I want to assign a name for my project
4
- So that license audit reports indicate their associated project
5
-
6
- Scenario: Specifying a project name
7
- Given I have an app
8
- When I set the project name to new_project
9
- And I run license_finder
10
- Then I should see the project name new_project in the html
@@ -1,27 +0,0 @@
1
- Feature: Whitelist licenses
2
- As a developer
3
- I want to whitelist certain OSS licenses that my business has pre-approved
4
- So that any dependencies with those licenses do not show up as action items
5
-
6
- Scenario: Adding a license to the whitelist
7
- Given I have an app
8
- When I whitelist the Expat license
9
- And I view the whitelisted licenses
10
- Then I should see Expat in the output
11
-
12
- Scenario: Depending on whitelisted licenses
13
- Given I have an app that depends on an BSD license
14
- When I whitelist the BSD license
15
- Then I should not see a BSD licensed gem unapproved
16
-
17
- Scenario: Removing a license from the whitelist
18
- Given I have an app
19
- When I whitelist the Expat license
20
- And I remove Expat from the whitelist
21
- And I view the whitelisted licenses
22
- Then I should not see Expat in the output
23
-
24
- Scenario: Whitelisting license aliases
25
- Given I have an app that depends on an MIT license
26
- When I whitelist the Expat license
27
- Then I should not see a MIT licensed gem unapproved
@@ -1,9 +0,0 @@
1
- Feature: Tracking Gradle Dependencies
2
- So that I can track Gradle dependencies
3
- As an application developer using license finder
4
- I want to be able to manage Gradle dependencies
5
-
6
- Scenario: See the dependencies from the build.gradle file
7
- Given A build.gradle file with dependencies
8
- When I run license_finder
9
- Then I should see a Gradle dependency with a license
@@ -1,19 +0,0 @@
1
- Feature: Manually Adding Dependencies
2
- So that I can track dependencies not managed by Bundler, NPM, etc.
3
- As an application developer using license finder
4
- I want to be able to manually add dependencies
5
-
6
- Scenario: Manually adding dependency
7
- Given I have an app
8
- When I add my JS dependency
9
- Then I should see the JS dependency in the console output
10
-
11
- Scenario: Auto approving a manually added dependency
12
- Given I have an app
13
- When I add my JS dependency with an approval flag
14
- Then I should not see the JS dependency in the console output
15
-
16
- Scenario: Removing a manually added dependency
17
- Given I have an app and a JS dependency
18
- When I remove my JS dependency
19
- Then I should not see the JS dependency in the console output
@@ -1,10 +0,0 @@
1
- Feature: Approving non-whitelisted Dependencies
2
- So that I can track the dependencies of my application which my business has approved
3
- As an application developer using license finder
4
- I want to be able to manually approve dependencies that have licenses which fall outside of my whitelist
5
-
6
- Scenario: Approving a non-whitelisted dependency
7
- Given I have an app that depends on a GPL licensed gem
8
- When I approve that gem
9
- Then I should not see that gem in the console output
10
- And I should see that gem approved in dependencies.html
@@ -1,16 +0,0 @@
1
- Feature: Setting a dependency's license
2
- So that my dependencies all have the correct licenses
3
- As an application developer
4
- I want to be able to manually set licenses
5
-
6
- Scenario: Setting a license for a dependency
7
- Given I have an app that depends on a few gems without known licenses
8
- When I set one gem's license to MIT from the command line
9
- Then I should see that gem's license set to MIT
10
- And I should see other gems have not changed their licenses
11
-
12
- Scenario: Keep manually assigned license dependencies
13
- Given I have an app that depends on a manually licensed gem
14
- When I run license_finder
15
- Then the gem should keep its manually assigned license
16
-