Added some tests

This commit is contained in:
Dolan
2017-06-08 01:57:03 +01:00
parent 66a6426d59
commit 98e2a4a83f
3 changed files with 67 additions and 4 deletions

View File

@@ -3,11 +3,36 @@ import { Oid } from './oid';
import { Reference } from './reference';
export class AnnotatedCommit {
static fromFetchhead(repo: Repository, branch_name: string, remote_url: string, id: Oid): Promise<AnnotatedCommit>;
/**
*
*
* @static
* @param {Repository} repo - repository that contains the given commit
* @param {string} branchName - name of the (remote) branch
* @param {string} remoteUrl - url of the remote
* @param {Oid} id - the commit object id of the remote branch
* @returns {Promise<AnnotatedCommit>}
*
* @memberof AnnotatedCommit
*/
static fromFetchhead(repo: Repository, branchName: string, remoteUrl: string, id: Oid): Promise<AnnotatedCommit>;
static fromRef(repo: Repository, ref: Reference): Promise<AnnotatedCommit>;
static fromRevspec(repo: Repository, revspec: string): Promise<AnnotatedCommit>;
static lookup(repo: Repository, id: Oid): Promise<AnnotatedCommit>;
/**
*
*
*
* @memberof AnnotatedCommit
*/
free(): void;
/**
*
*
* @returns {Oid}
*
* @memberof AnnotatedCommit
*/
id(): Oid;
}