Skip to content

Commit

Permalink
Removed debugging code.
Browse files Browse the repository at this point in the history
  • Loading branch information
bkstein committed Dec 6, 2023
1 parent 0abe441 commit 572d2d0
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions der/src/asn1/octet_string.rs
Original file line number Diff line number Diff line change
Expand Up @@ -244,15 +244,13 @@ mod bytes {
#[cfg(test)]
#[allow(clippy::unwrap_used)]
mod tests {
use crate::asn1::{OctetString, OctetStringRef, PrintableStringRef};
use crate::asn1::{OctetStringRef, PrintableStringRef};

#[test]
fn octet_string_decode_into() {
// PrintableString "hi"
let der = b"\x13\x02\x68\x69";
let oct = OctetStringRef::new(der).unwrap();
let oct_owned = OctetString::new("Halllo".as_bytes()).unwrap();
assert!(!oct_owned.is_empty());

let res = oct.decode_into::<PrintableStringRef<'_>>().unwrap();
assert_eq!(AsRef::<str>::as_ref(&res), "hi");
Expand Down

0 comments on commit 572d2d0

Please sign in to comment.