monotone

monotone Mtn Source Tree

Root/notes/testsuite.txt

1
2Functions and variables specific for the monotone testsuite (testsuite.lua)
3---------------------------------------------------------------------------
4
5ostype
6
7For convenience, this is the first word of what get_ostype() returns.
8
9getpathof(exe, ext) [internal]
10
11Used to find the mtn executable. This looks in cwd before searching the
12path.
13
14monotone_path
15
16Set the the path of the mtn executable. If the testsuite is run from a
17dir containing an mtn executable, that executable is used instead of any
18that might be on the path.
19
20mtn [env var]
21
22Set to monotone_path. This is used by one of the test hooks, for file:/
23sync.
24
25safe_mtn() [internal]
26raw_mtn()
27
28A monotone that won't escape the test dir.
29
30mtn()
31
32A monotone with most of the boilerplate options. You probably want to
33use this one.
34
35minhooks_mtn()
36
37Like mtn(), but it uses a different hooks file.
38
39commit([branch [, message [, mt]]])
40
41Commit to the given branch, or "testbranch". Uses mtn(), or mt() if that
42is given.
43
44sha1(file)
45
46Return the hash of the given file.
47
48probe_node(filename, rsha, fsha)
49
50Check out a given revision, and check that a given file has the correct
51hash.
52
53mtn_setup()
54
55General setup, always call this first.
56
57base_revision()
58base_manifest()
59
60Return hashes associated with the workspace base revision.
61
62certvalue(rev, name)
63
64Return the value of the given cert. If there are multiple certs matched,
65only return the first one.
66
67qgrep(what, where)
68
69More convenient than using grep("-q", ...). Returns true/false.
70
71addfile(filename, contents [, mt])
72
73Write the given file, then add it (Using the specified monotone,
74if given).
75
76adddir(dirname [, mt])
77
78Adds the specified directory to monotone (using the given monotone
79 instance or the global one). Checks if the path is a directory at all,
80 if not tries to create the directory.
81
82revert_to(rev, branch [, mt])
83
84Use "mtn checkout" to set the workspace to the given branch and revision.
85
86canonicalize(filename)
87
88When used on Windows, make sure that the given file uses "\n" line
89endings.
90
91check_same_db_contents(db1, db2)
92
93check_{same,different}_stdout(cmd, cmd)
94Compare stdout of the two commands.
95
96check_{same,different}_stdout(args, fn1, fn2)
97Compare the output of the two commands, when given the specified args.
98
99write_large_file(filename, size)
100
101Write a size MB random file.
102

Archive Download this file

Branches

Tags

Quick Links:     www.monotone.ca    -     Downloads    -     Documentation    -     Wiki    -     Code Forge    -     Build Status