Skip to content

Commit 093ea31

Browse files
committed
Replaced cfg_attr no_std with blanket no_std and extern crate in tests module
1 parent 125acdd commit 093ea31

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/lib.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
//! contains detailed information about the sensor's features, electrical characteristics, and registers. This package
2929
//! implements the functionality described in the datasheet and references the relevant sections in the documentation.
3030
31-
#![cfg_attr(not(test), no_std)]
31+
#![no_std]
3232

3333
use defmt::{debug, trace, Format};
3434
use embedded_hal_async::{delay::DelayNs, i2c::I2c};
@@ -692,6 +692,9 @@ where
692692

693693
#[cfg(test)]
694694
mod tests {
695+
extern crate std;
696+
use std::prelude::rust_2021::*;
697+
use std::vec;
695698
use embedded_hal_mock::eh1::delay::{CheckedDelay, NoopDelay, Transaction as DelayTransaction};
696699
use embedded_hal_mock::eh1::i2c::{Mock, Transaction as I2cTransaction};
697700
use uom::ConstZero;

0 commit comments

Comments
 (0)