From 395602e523baf561bab9f6e5a6f7f7413fd09c1b Mon Sep 17 00:00:00 2001 From: Stjepan Rajko Date: Mon, 25 Apr 2016 18:00:02 -0700 Subject: [PATCH] Move reflog entry methods to ReflogEntry --- generate/input/libgit2-supplement.json | 17 +++++++++++++++++ test/tests/commit.js | 4 ++-- 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/generate/input/libgit2-supplement.json b/generate/input/libgit2-supplement.json index 78f954255..d8d34e5fa 100644 --- a/generate/input/libgit2-supplement.json +++ b/generate/input/libgit2-supplement.json @@ -268,6 +268,15 @@ "git_patch_convenient_from_diff" ] ], + [ + "reflog_entry", + [ + "git_reflog_entry_committer", + "git_reflog_entry_id_new", + "git_reflog_entry_id_old", + "git_reflog_entry_message" + ] + ], [ "revwalk", [ @@ -705,6 +714,14 @@ "git_merge_head_id" ] }, + "reflog": { + "functions": [ + "git_reflog_entry_committer", + "git_reflog_entry_id_new", + "git_reflog_entry_id_old", + "git_reflog_entry_message" + ] + }, "status": { "functions": [ "git_status_list_entrycount", diff --git a/test/tests/commit.js b/test/tests/commit.js index f4e7d94ac..c21aa6df9 100644 --- a/test/tests/commit.js +++ b/test/tests/commit.js @@ -367,11 +367,11 @@ describe("Commit", function() { }).then(function(reflog) { var reflogEntry = reflog.entryByIndex(0); assert.equal( - NodeGit.Reflog.entryMessage(reflogEntry), + reflogEntry.message(), customReflogMessage ); assert.equal( - NodeGit.Reflog.entryIdNew(reflogEntry).toString(), + reflogEntry.idNew().toString(), oid ); // only setTarget should have added to the entrycount