Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
varnish-cache
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
varnishcache
varnish-cache
Commits
4bc28383
Commit
4bc28383
authored
Apr 07, 2018
by
Poul-Henning Kamp
Committed by
Dridi Boukelmoune
Jun 19, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Even more Teken coverage
parent
42e15a10
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
105 additions
and
2 deletions
+105
-2
a00001.vtc
bin/varnishtest/tests/a00001.vtc
+101
-0
vtc_process.c
bin/varnishtest/vtc_process.c
+4
-2
No files found.
bin/varnishtest/tests/a00001.vtc
View file @
4bc28383
...
...
@@ -7,6 +7,7 @@ process p4 {vttest} -start
process p4 -expect-text 21 11 "Enter choice number (0 - 12):"
process p4 -screen_dump
# 1. Test of cursor movements
process p4 -writehex "31 0d"
process p4 -expect-text 14 61 "RETURN"
process p4 -screen_dump
...
...
@@ -37,6 +38,7 @@ process p4 -writehex 0d
process p4 -expect-text 21 11 "Enter choice number (0 - 12):"
process p4 -screen_dump
# 2. Test of screen features
process p4 -writehex "32 0d"
process p4 -expect-text 8 1 "Push <RETURN>"
process p4 -screen_dump
...
...
@@ -104,6 +106,105 @@ process p4 -writehex 0d
process p4 -expect-text 21 11 "Enter choice number (0 - 12):"
process p4 -screen_dump
# 4. Test of double-sized characters
process p4 -writehex "34 0d"
process p4 -expect-text 21 1 "This is not a double-width line"
process p4 -expect-text 23 1 "Push <RETURN>"
process p4 -screen_dump
process p4 -writehex "0d"
process p4 -expect-text 21 1 "This **is** a double-width line"
process p4 -expect-text 23 1 "Push <RETURN>"
process p4 -screen_dump
process p4 -writehex "0d"
process p4 -expect-text 21 1 "This is not a double-width line"
process p4 -expect-text 23 1 "Push <RETURN>"
process p4 -screen_dump
process p4 -writehex "0d"
process p4 -expect-text 21 1 "This **is** a double-width line"
process p4 -expect-text 23 1 "Push <RETURN>"
process p4 -screen_dump
process p4 -writehex "0d"
delay 2
process p4 -expect-text 23 41 "Push <RETURN>"
process p4 -screen_dump
process p4 -writehex "0d"
delay 2
process p4 -expect-text 1 1 "Exactly half of the box should remain. Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 21 11 "Enter choice number (0 - 12):"
process p4 -screen_dump
# 8. Test of VT102 features (Insert/Delete Char/Line)
process p4 -writehex "38 0d"
process p4 -expect-text 4 1 "Screen accordion test (Insert & Delete Line). Push <RETURN>D"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 2 45 "nothing more. Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 4 59 "*B'. Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 4 52 "'AB'. Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 5 1 "by one. Push <RETURN>E"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 5 1 "by one. Push <RETURN>EEEEEEEEEEEEE "
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 10 1 "Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 4 1 "Screen accordion test (Insert & Delete Line). Push <RETURN>D"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 2 45 "nothing more. Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 4 59 "*B'. Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 4 52 "'AB'. Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 5 1 "by one. Push <RETURN>E"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 5 59 "EEE "
process p4 -expect-text 5 1 "by one. Push <RETURN>E"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 10 1 "Push <RETURN>"
process p4 -screen_dump
process p4 -writehex 0d
process p4 -expect-text 21 11 "Enter choice number (0 - 12):"
process p4 -screen_dump
# 0. Exit
process p4 -writehex "30 0d"
process p4 -expect-text 12 30 "That's all, folks!"
process p4 -screen_dump
...
...
bin/varnishtest/vtc_process.c
View file @
4bc28383
...
...
@@ -289,7 +289,7 @@ static void
term_expect_text
(
struct
process
*
pp
,
const
char
*
lin
,
const
char
*
col
,
const
char
*
pat
)
{
int
x
,
y
,
l
;
int
x
,
y
,
l
,
d
=
10000
;
char
*
t
;
y
=
strtoul
(
lin
,
NULL
,
0
);
...
...
@@ -303,8 +303,10 @@ term_expect_text(struct process *pp,
"text at %d,%d: '%.*s'"
,
y
,
x
,
l
,
t
);
}
AZ
(
pthread_mutex_unlock
(
&
pp
->
mtx
));
usleep
(
1000000
);
usleep
(
d
);
AZ
(
pthread_mutex_lock
(
&
pp
->
mtx
));
if
(
d
<
300000
)
d
+=
d
;
}
AZ
(
pthread_mutex_unlock
(
&
pp
->
mtx
));
vtc_log
(
pp
->
vl
,
4
,
"found expected text at %d,%d: '%s'"
,
y
,
x
,
pat
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment