From 522b54fd531f8f18eb22d1d46d34913f50a95e12 Mon Sep 17 00:00:00 2001 From: Gwilym Kuiper Date: Tue, 11 Oct 2022 22:25:56 +0100 Subject: [PATCH] Make vscode not give me an error with hyperspace-roll and the-purple-night --- examples/hyperspace-roll/src/main.rs | 3 +++ examples/the-purple-night/src/main.rs | 3 +++ 2 files changed, 6 insertions(+) diff --git a/examples/hyperspace-roll/src/main.rs b/examples/hyperspace-roll/src/main.rs index cd61df84..3d1d46c7 100644 --- a/examples/hyperspace-roll/src/main.rs +++ b/examples/hyperspace-roll/src/main.rs @@ -9,6 +9,9 @@ // 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] +#![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::object::ObjectController; use agb::display::tiled::{TiledMap, VRamManager}; diff --git a/examples/the-purple-night/src/main.rs b/examples/the-purple-night/src/main.rs index 922b4e3a..a4ea3ae2 100644 --- a/examples/the-purple-night/src/main.rs +++ b/examples/the-purple-night/src/main.rs @@ -1,5 +1,8 @@ #![no_std] #![no_main] +#![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))] extern crate alloc;