Update the template to have testing available

This commit is contained in:
Gwilym Kuiper 2022-07-03 18:30:58 +01:00
parent 0111ec43bb
commit 208104d036
2 changed files with 7 additions and 0 deletions

View file

@ -9,6 +9,9 @@ edition = "2018"
[dependencies]
agb = "0.9.2"
[dev-dependencies]
agb = { version = "0.9.2", features = ["testing"] }
[profile.release]
panic = "abort"
lto = true

View file

@ -9,6 +9,10 @@
// using the #[agb::entry] proc macro. Failing to do so will cause failure in linking
// which won't be a particularly clear error message.
#![no_main]
// This is required to allow writing tests
#![cfg_attr(test, feature(custom_test_frameworks))]
#![cfg_attr(test, reexport_test_harness_main = "test_main")]
#![cfg_attr(test, test_runner(agb::test_runner::test_runner))]
use agb::{display, syscall};