mirror of
https://github.com/documentationjs/documentation.git
synced 2026-01-18 14:17:30 +00:00
* Fixed find_git test for windows platform. * Fixed github test on windows platform. * Fixed bin tests which are executed process from node.js * On windows platform uses DOUBLE EXCLAMATION MARK instead of WARNING SIGN.
25 lines
496 B
JavaScript
25 lines
496 B
JavaScript
'use strict';
|
|
|
|
var test = require('tap').test,
|
|
mock = require('mock-fs'),
|
|
mockRepo = require('./mock_repo'),
|
|
path = require('path'),
|
|
findGit = require('../../../lib/git/find_git');
|
|
|
|
test('findGit', function (t) {
|
|
|
|
mock(mockRepo.master);
|
|
|
|
const root = path.parse(__dirname).root;
|
|
|
|
t.equal(
|
|
findGit(
|
|
root + path.join('my', 'repository', 'path', 'index.js')),
|
|
root + path.join('my', 'repository', 'path', '.git'), 'finds git path');
|
|
|
|
mock.restore();
|
|
|
|
t.end();
|
|
});
|
|
|