Skip to content

Commit ffd7226

Browse files
committed
repo.write test
1 parent 71ed902 commit ffd7226

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

test/test.repo.js

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -65,13 +65,23 @@ test('Create Repo', function(t) {
6565
});
6666
var user = github.getUser();
6767

68-
user.createRepo({ "name": repoTest }, function (err, res) {
69-
t.error(err);
70-
t.equals(res.name, repoTest.toString(), 'Repo created');
71-
clearTimeout(timeout);
72-
t.end();
68+
t.test('user.createRepo', function(q) {
69+
user.createRepo({ "name": repoTest }, function (err, res) {
70+
q.error(err);
71+
q.equals(res.name, repoTest.toString(), 'Repo created');
72+
q.end();
73+
});
7374
});
75+
var repo = github.getRepo(test_user.USERNAME, repoTest);
7476

77+
t.test('repo.write', function(q) {
78+
repo.write('master', 'TEST.md', 'THIS IS A TEST', 'Creating test', function(err) {
79+
q.error(err);
80+
q.end();
81+
});
82+
});
83+
clearTimeout(timeout);
84+
t.end();
7585
});
7686

7787
test('delete Repo', function(t) {

0 commit comments

Comments
 (0)