File: backend_helpers.h

package info (click to toggle)
libgit2 0.27.7%2Bdfsg.1-0.2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 31,400 kB
  • sloc: ansic: 157,824; sh: 406; python: 182; php: 65; makefile: 61
file content (22 lines) | stat: -rw-r--r-- 386 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include "git2/sys/odb_backend.h"

typedef struct {
	const char *oid;
	const char *content;
} fake_object;

typedef struct {
	git_odb_backend parent;

	int exists_calls;
	int exists_prefix_calls;
	int read_calls;
	int read_header_calls;
	int read_prefix_calls;

	const fake_object *objects;
} fake_backend;

int build_fake_backend(
	git_odb_backend **out,
	const fake_object *objects);