diff options
author | Ruy Adorno <ruyadorno@hotmail.com> | 2019-11-20 00:32:57 +0300 |
---|---|---|
committer | Michael Perrotte <mike@npmjs.com> | 2019-12-03 20:13:43 +0300 |
commit | 1c65d26ac9f10ac0037094c207d216fbf0e969bf (patch) | |
tree | d3588f74b51b66f024df0c9f0e66d9a0cf695bb4 /tap-snapshots | |
parent | e4b97962e5fce0d49beb541ce5a0f96aee0525de (diff) |
fix(fund): open url for string shorthand
Trying to open url for a package that is using the string shorthand is
currently broken using: `npm fund <pkg>`
This commit fixes the issue and adds the missing unit and integration
tests covering that usecase.
Fixes #498
PR-URL: https://github.com/npm/cli/pull/501
Credit: @ruyadorno
Close: #501
Reviewed-by: @mikemimik
Diffstat (limited to 'tap-snapshots')
-rw-r--r-- | tap-snapshots/test-tap-fund.js-TAP.test.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tap-snapshots/test-tap-fund.js-TAP.test.js b/tap-snapshots/test-tap-fund.js-TAP.test.js index e351a21c6..eb3183a27 100644 --- a/tap-snapshots/test-tap-fund.js-TAP.test.js +++ b/tap-snapshots/test-tap-fund.js-TAP.test.js @@ -47,6 +47,13 @@ http://example.com/donate ` +exports[`test/tap/fund.js TAP fund using string shorthand > should open string-only url 1`] = ` +Funding available at the following URL: + +https://example.com/sponsor + +` + exports[`test/tap/fund.js TAP fund with no package containing funding > should print empty funding info 1`] = ` no-funding-package@0.0.0 |