diff options
author | Samy Pessé <samypesse@gmail.com> | 2016-05-27 09:27:11 +0200 |
---|---|---|
committer | Samy Pessé <samypesse@gmail.com> | 2016-05-27 09:27:11 +0200 |
commit | 6def174b845d6dd392c2f1ef41e94b025b774bf8 (patch) | |
tree | c2c2825fbf2e504202367c4843fa8c63e5cc4d4e /lib/plugins/__tests__/resolveVersion.js | |
parent | 346a18b4446060eeb53a0a697fa82f1d13ba6cd2 (diff) | |
parent | 465e8d6c0adfe69f696fafa7486541aac55298fe (diff) | |
download | gitbook-6def174b845d6dd392c2f1ef41e94b025b774bf8.zip gitbook-6def174b845d6dd392c2f1ef41e94b025b774bf8.tar.gz gitbook-6def174b845d6dd392c2f1ef41e94b025b774bf8.tar.bz2 |
Merge pull request #1334 from ryanswanson/master
Fixed two issues for handling git URLs for plugins
Diffstat (limited to 'lib/plugins/__tests__/resolveVersion.js')
-rw-r--r-- | lib/plugins/__tests__/resolveVersion.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/plugins/__tests__/resolveVersion.js b/lib/plugins/__tests__/resolveVersion.js new file mode 100644 index 0000000..164611f --- /dev/null +++ b/lib/plugins/__tests__/resolveVersion.js @@ -0,0 +1,14 @@ +var PluginDependency = require('../../models/pluginDependency'); +var resolveVersion = require('../resolveVersion'); + +describe('resolveVersion', function() { + it('must skip resolving and return non-semver versions', function(done) { + var plugin = PluginDependency.createFromString('plugin-ga@git+ssh://samy@github.com/GitbookIO/plugin-ga.git'); + + resolveVersion(plugin) + .then(function(version) { + expect(version).toBe('git+ssh://samy@github.com/GitbookIO/plugin-ga.git'); + done(); + }); + }); +}); |