File: 14-tabstop.t

package info (click to toggle)
libterm-vt102-perl 0.91-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 268 kB
  • sloc: perl: 2,471; makefile: 13
file content (33 lines) | stat: -rw-r--r-- 1,897 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
#!/usr/bin/perl -w
#
# Make sure the VT102 module can handle tabs and tab stops.
#
# Copyright (C) Andrew Wood
# NO WARRANTY - see COPYING.
#

require Term::VT102;
require 't/testbase';

my $tabs = "a\tb\tc\td\te\tf\tg\th\ti\tj\tk";
run_tests ([(
  [ 80, 9,
    "Line 1\r". $tabs ."\r\nLine 2\e[3g\r\nLine 3\r" . $tabs . "\r\n" .
    "Line 4\e[3g\e[9G\eHt\e[17G\eHt\e[25G\eHt\e[33G\eHt\e[41G\eHt\e[49G\eHt\e[57G\eHt\e[65G\eHt\e[73G\eHt\r\n" .
    "Line 5\r" . $tabs . "\r\n" .
    "Line 6\e[17G\e[gT\r" . $tabs . "\r\n" .
    "Line 7\e[3g\e[5G\eHt\e[10G\eHt\e[15G\eHt\e[20G\eHt\r\n" .
    "Line 8\r" . $tabs . "\r\n",
    "aine 1\0\0b\0\0\0\0\0\0\0c\0\0\0\0\0\0\0d\0\0\0\0\0\0\0e\0\0\0\0\0\0\0f\0\0\0\0\0\0\0g\0\0\0\0\0\0\0h\0\0\0\0\0\0\0i\0\0\0\0\0\0\0j\0\0\0\0\0\0k",
    "Line 2\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",
    "aine 3\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\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