Skip to content

Commit

Permalink
Merge pull request #26 from diseraluca/issue_25/avoiding_the_missing_…
Browse files Browse the repository at this point in the history
…generation_of_getters_for_the_test_build

Issue 25/avoiding the missing generation of getters for the test build
  • Loading branch information
diseraluca authored May 31, 2021
2 parents 011b77a + eb49ecf commit 966b3a7
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#![no_std]
#![feature(cfg_eval)]

pub mod rx;
pub mod session_id;
Expand Down
3 changes: 2 additions & 1 deletion src/session_id/message.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
use super::{node_id::NodeId, subject_id::SubjectId, transfer_priority::TransferPriority};
use modular_bitfield::prelude::*;

#[cfg_eval]
#[bitfield]
#[repr(u32)]
#[derive(Debug, Copy, Clone, PartialEq, Eq)]
Expand All @@ -20,7 +21,7 @@ pub struct MessageSessionId {
is_anonymous: bool,
pub is_service: bool,
#[bits = 3]
#[skip(getters)]
#[cfg_attr(not(test), skip(getters))]
priority: TransferPriority,
#[skip]
__: B3,
Expand Down
2 changes: 1 addition & 1 deletion src/tail_byte/tail_byte.rs
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ mod tests {
fn the_successor_of_a_tail_byte_has_the_same_transfer_id_as_the_original_tail_byte(
) {
let mut tail_byte = TailByte::start_of_multi_frame(TransferId::try_from(0).unwrap());
let mut original_transfer_id = tail_byte.transfer_id();
let original_transfer_id = tail_byte.transfer_id();

tail_byte.advance();

Expand Down

0 comments on commit 966b3a7

Please sign in to comment.