File: __driver__.lua

package info (click to toggle)
monotone 1.1-9
  • links: PTS, VCS
  • area: main
  • in suites: stretch
  • size: 20,984 kB
  • ctags: 8,622
  • sloc: cpp: 86,450; sh: 6,906; perl: 924; makefile: 813; python: 517; lisp: 379; sql: 118; exp: 91; ansic: 52
file content (36 lines) | stat: -rw-r--r-- 935 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
23
24
25
26
27
28
29
30
31
32
33
34
35
36
-- Test 'mtn automate log'

mtn_setup()

-- empty branch
check(mtn("automate", "log"), 0, false, true)
check(qgrep("warning: workspace has no parent revision,", "stderr"))

includecommon("automate_ancestry.lua")
includecommon("automate_stdio.lua")

revs = make_graph()
--   A
--  / \
-- B   C
--     |\
--     D E
--     \/
--      F
-- workspace is at F

-- Default 'from' is F
-- '--to' is not inclusive; '--from' is.
revmap("log", {"--to", revs.a}, {revs.f, revs.d, revs.e, revs.c}, false)
revmap("log", {"--to", revs.b, "--from", revs.b}, {revs.b}, false)
revmap("log", {"--to", revs.e}, {revs.f, revs.d}, false)
revmap("log", {"--to", revs.c, "--from", revs.d}, {revs.d}, false)

-- show missing revisions
revert_to(revs.c)
revmap("log", {"--to", "w:", "--from", "h:"}, {revs.b, revs.f, revs.d, revs.e}, false)

-- test automate stdio log
check(run_stdio("l3:loge", 0, 0, "m") == revs.c .. "\n" .. revs.a .. "\n")

-- end of file