summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authormo khan <mo.khan@gmail.com>2020-05-19 11:06:04 -0600
committermo khan <mo.khan@gmail.com>2020-05-19 11:06:04 -0600
commitea84a8f5badf153744486c51a75b1f492763fdfd (patch)
treea719f96141eb621b71baa23e6d0a86f0849053e7 /spec
parent5e6cad59f389ea4c32eb760e7235e6f1ac6cdcc9 (diff)
Add bower dependencies and expected assertions
Diffstat (limited to 'spec')
-rw-r--r--spec/fixtures/js/bower/bower.json8
-rw-r--r--spec/integration/js/bower_spec.rb5
2 files changed, 12 insertions, 1 deletions
diff --git a/spec/fixtures/js/bower/bower.json b/spec/fixtures/js/bower/bower.json
index 9a905fd..4cfbefc 100644
--- a/spec/fixtures/js/bower/bower.json
+++ b/spec/fixtures/js/bower/bower.json
@@ -8,5 +8,11 @@
"bower_components",
"test",
"tests"
- ]
+ ],
+ "dependencies": {
+ "jquery": "^3.5.1",
+ "masonry-layout": "desandro/masonry#^4.2.2",
+ "cli": "git://github.com/npm/cli.git#^6.14.5",
+ "stimulus.umd": "https://unpkg.com/stimulus/dist/stimulus.umd.js"
+ }
}
diff --git a/spec/integration/js/bower_spec.rb b/spec/integration/js/bower_spec.rb
index d2fb682..68ab12d 100644
--- a/spec/integration/js/bower_spec.rb
+++ b/spec/integration/js/bower_spec.rb
@@ -9,5 +9,10 @@ RSpec.describe "bower" do
end
specify { expect(subject).to match_schema(version: '2.0') }
+ specify { expect(subject.dependency_names).to match_array(['cli', 'jquery', 'masonry-layout', 'stimulus.umd']) }
+ specify { expect(subject.licenses_for('cli')).to match_array(['Artistic-2.0']) }
+ specify { expect(subject.licenses_for('jquery')).to match_array(['MIT']) }
+ specify { expect(subject.licenses_for('masonry-layout')).to match_array(['MIT']) }
+ specify { expect(subject.licenses_for('stimulus.umd')).to match_array(['MIT']) }
end
end