about summary refs log tree commit diff
path: root/nixos/doc/manual/development
diff options
context:
space:
mode:
authorsternenseemann <sternenseemann@systemli.org>2022-03-26 09:59:28 +0100
committersternenseemann <sternenseemann@systemli.org>2022-03-26 09:59:28 +0100
commit372d0a707e13e20443543461ff4f7c00454dea8c (patch)
treeca619a9578bd21b04841c5aade7e9e5f38b19145 /nixos/doc/manual/development
parent66996acc2a9afd1b0c34beffc2bab3e8daecbcad (diff)
parentb9eab51eed6fb41c85bcda2d6241f151735c853a (diff)
Merge remote-tracking branch 'origin/master' into haskell-updates
Diffstat (limited to 'nixos/doc/manual/development')
-rw-r--r--nixos/doc/manual/development/writing-nixos-tests.section.md13
1 files changed, 13 insertions, 0 deletions
diff --git a/nixos/doc/manual/development/writing-nixos-tests.section.md b/nixos/doc/manual/development/writing-nixos-tests.section.md
index 7de57d0d2a379..433e1906f7756 100644
--- a/nixos/doc/manual/development/writing-nixos-tests.section.md
+++ b/nixos/doc/manual/development/writing-nixos-tests.section.md
@@ -158,6 +158,12 @@ The following methods are available on machine objects:
     e.g., `send_chars("foobar\n")` will type the string `foobar`
     followed by the Enter key.
 
+`send_console`
+
+:   Send keys to the kernel console. This allows interaction with the systemd
+    emergency mode, for example. Takes a string that is sent, e.g.,
+    `send_console("\n\nsystemctl default\n")`.
+
 `execute`
 
 :   Execute a shell command, returning a list `(status, stdout)`.
@@ -272,6 +278,13 @@ The following methods are available on machine objects:
     Killing the interactive session with `Ctrl-d` or `Ctrl-c` also ends
     the guest session.
 
+`console_interact`
+
+:   Allows you to directly interact with QEMU's stdin. This should
+    only be used during test development, not in production tests.
+    Output from QEMU is only read line-wise. `Ctrl-c` kills QEMU and
+    `Ctrl-d` closes console and returns to the test runner.
+
 To test user units declared by `systemd.user.services` the optional
 `user` argument can be used: