Commit graph

60 commits

Author SHA1 Message Date
6e04ffdcbe os.be.*.Machine: Rename CPU -> DUT
Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
1c674dfa3f Add test.cmds_exec()
test.cmds_exec() takes a list of lists with commands to be sent to a
console, returns None on success and an error message on failure.

The list can consist of up to three entries, 2 + 3 are optional:

  [ cmd, expect-regex, timeout]

Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
7d709ecc58 os.misc.cmd_exec(): Fix echo_cmd=False
cmd_exec() sometimes returned the command in the output albeit
echo_cmd=False was specified, notably if the command contained a
newline.

Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
0f723cfd1b test.cases.ProcMounts: Add ":" to device name regex
Devices may be called ubi0:rescue0 or so.

Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
5b54b637fd os.conn.Serial: Don't use line_buffering in fdopen()
It's wrong to use line buffering in fdopen(..., ".b"), there's no
such thing as a line in binary data, also see

	https://bugs.python.org/issue32236

Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
142c1dbf6d Add support for test-os --cases option
Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
765e6f3a1b Add test.cases.LsofUds
Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
e0819d7c39 Add test.cases.LsofNet
Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
03da0449c4 Add test/list-cmd
Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:26 +01:00
4b912741cb First commit
Signed-off-by: Jan Lindemann <jan@janware.com>
2025-11-17 11:12:21 +01:00