1
0
mirror of https://github.com/sehugg/8bitworkshop.git synced 2026-01-22 23:16:23 +00:00

github: check repo existence before importing

This commit is contained in:
Steven Hugg
2019-08-22 12:42:48 -04:00
parent 3a2df124eb
commit 84a6c6ff61
4 changed files with 22 additions and 7 deletions

View File

@@ -70,6 +70,17 @@ describe('Store', function() {
});
});
it('Should import from Github (invalid URL)', function(done) {
var store = mstore.createNewPersistentStore('_FOO', function(store) {
var gh = newGH(store, '_FOO');
gh.importAndPull('https://github.com/pzpinfo/NOEXISTSREPO').catch( (e) => {
console.log(e);
assert.deepEqual(serv.getRepos(), {});
done();
});
});
});
it('Should import from Github (subdirectory tree)', function(done) {
var store = mstore.createNewPersistentStore('nes', function(store) {
var gh = newGH(store, 'nes');