Browse Source

refactor(tests): Move remaining tests to posix 64.

* Update docs and fix up a few lingering tests
  to consistently use native_posix_64 target.
xmkb
Peter Johanson 3 years ago committed by Pete Johanson
parent
commit
64dadfb336
  1. 0
      app/tests/hold-tap/balanced/8-global-quick-tap/1-basic/native_posix_64.keymap
  2. 0
      app/tests/hold-tap/balanced/8-global-quick-tap/2-double-hold/native_posix_64.keymap
  3. 0
      app/tests/hold-tap/hold-preferred/8-global-quick-tap/1-basic/native_posix_64.keymap
  4. 0
      app/tests/hold-tap/hold-preferred/8-global-quick-tap/2-double-hold/native_posix_64.keymap
  5. 0
      app/tests/hold-tap/tap-preferred/8-global-quick-tap/1-basic/native_posix_64.keymap
  6. 0
      app/tests/hold-tap/tap-preferred/8-global-quick-tap/2-double-hold/native_posix_64.keymap
  7. 0
      app/tests/hold-tap/tap-unless-interrupted/6-global-quick-tap/1-basic/native_posix_64.keymap
  8. 0
      app/tests/hold-tap/tap-unless-interrupted/6-global-quick-tap/2-double-hold/native_posix_64.keymap
  9. 8
      docs/docs/development/posix-board.md
  10. 4
      docs/docs/development/tests.md

0
app/tests/hold-tap/balanced/8-global-quick-tap/1-basic/native_posix.keymap → app/tests/hold-tap/balanced/8-global-quick-tap/1-basic/native_posix_64.keymap

0
app/tests/hold-tap/balanced/8-global-quick-tap/2-double-hold/native_posix.keymap → app/tests/hold-tap/balanced/8-global-quick-tap/2-double-hold/native_posix_64.keymap

0
app/tests/hold-tap/hold-preferred/8-global-quick-tap/1-basic/native_posix.keymap → app/tests/hold-tap/hold-preferred/8-global-quick-tap/1-basic/native_posix_64.keymap

0
app/tests/hold-tap/hold-preferred/8-global-quick-tap/2-double-hold/native_posix.keymap → app/tests/hold-tap/hold-preferred/8-global-quick-tap/2-double-hold/native_posix_64.keymap

0
app/tests/hold-tap/tap-preferred/8-global-quick-tap/1-basic/native_posix.keymap → app/tests/hold-tap/tap-preferred/8-global-quick-tap/1-basic/native_posix_64.keymap

0
app/tests/hold-tap/tap-preferred/8-global-quick-tap/2-double-hold/native_posix.keymap → app/tests/hold-tap/tap-preferred/8-global-quick-tap/2-double-hold/native_posix_64.keymap

0
app/tests/hold-tap/tap-unless-interrupted/6-global-quick-tap/1-basic/native_posix.keymap → app/tests/hold-tap/tap-unless-interrupted/6-global-quick-tap/1-basic/native_posix_64.keymap

0
app/tests/hold-tap/tap-unless-interrupted/6-global-quick-tap/2-double-hold/native_posix.keymap → app/tests/hold-tap/tap-unless-interrupted/6-global-quick-tap/2-double-hold/native_posix_64.keymap

8
docs/docs/development/posix-board.md

@ -21,18 +21,18 @@ apt install -y gcc-multilib @@ -21,18 +21,18 @@ apt install -y gcc-multilib
## Building
To do this, you can build ZMK targeting the
`native_posix` board.
`native_posix_64` board.
```
west build --pristine --board native_posix
west build --pristine --board native_posix_64 -- -DZMK_CONFIG=tests/none/normal/
```
Once built, you can run the firmware locally:
```
./build/zephyr/zephyr.exe
./build/zephyr/zmk.exe
```
## Virtual Key Events
The virtual key presses are hardcoded in `boards/native_posix.overlay` file, should you want to change the sequence to test various actions like Mod-Tap, etc.
The virtual key presses are hardcoded in `boards/native_posix_64.overlay` file, should you want to change the sequence to test various actions like Mod-Tap, etc.

4
docs/docs/development/tests.md

@ -4,7 +4,7 @@ sidebar_label: Tests @@ -4,7 +4,7 @@ sidebar_label: Tests
---
- Running tests requires [native posix support](posix-board.md).
- Any folder under `/app/tests` containing `native_posix.keymap` will be selected when running `west test`.
- Any folder under `/app/tests` containing `native_posix_64.keymap` will be selected when running `west test`.
- Run tests from within the `/zmk/app` directory.
- Run a single test with `west test <testname>`, like `west test tests/toggle-layer/normal`.
@ -13,7 +13,7 @@ sidebar_label: Tests @@ -13,7 +13,7 @@ sidebar_label: Tests
1. Copy the test set that most closely resembles the tests you will be creating.
2. Rename the newly created test set to the behavior you're testing e.g, toggle-layer
3. Modify `behavior_keymap.dtsi` to create a keymap using the behavior and related behaviors
4. Modify `test_case/native_posix.keymap` for a simulated use case
4. Modify `test_case/native_posix_64.keymap` for a simulated use case
5. Modify `test_case/events.patterns` to collect relevant logs to the test
- See: [sed manual](https://www.gnu.org/software/sed/manual/sed.html) and
[tutorial](https://www.digitalocean.com/community/tutorials/the-basics-of-using-the-sed-stream-editor-to-manipulate-text-in-linux)

Loading…
Cancel
Save