Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
[![Tests Status](https://github.com/pbs-data-solutions/prelude-xml-parser/actions/workflows/testing.yml/badge.svg?branch=main&event=push)](https://github.com/pbs-data-solutions/prelude-xml-parser/actions?query=workflow%3ATesting+branch%3Amain+event%3Apush)
![crates.io](https://img.shields.io/crates/v/prelude-xml-parser.svg?color=brightgreen)

Deserialize Prelude EDC native XML files into Rust stucts. Enabling the `python` feature allows
Deserialize Prelude EDC native XML files into Rust structs. Enabling the `python` feature allows
deserializing to Python classes with PyO3.

## Supported native files
Expand Down
2 changes: 1 addition & 1 deletion src/errors.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ pub enum Error {
#[error("File {:?} is not a XML file.", 0)]
InvalidFileType(PathBuf),

/// The file was not found at the specififed path.
/// The file was not found at the specified path.
#[error("File was not found at the specified path: {:?}.", 0)]
FileNotFound(PathBuf),

Expand Down
12 changes: 6 additions & 6 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ use crate::native::{
use quick_xml::events::{BytesStart, Event};
use quick_xml::Reader;

/// Parses a Prelude native XML file into a `Native` stuct.
/// Parses a Prelude native XML file into a `Native` struct.
///
/// # Example
///
Expand Down Expand Up @@ -435,7 +435,7 @@ pub fn parse_site_native_string(xml_str: &str) -> Result<SiteNative, Error> {
Ok(native)
}

/// Parses a Prelude native subject XML file into a `SubjectNative` stuct.
/// Parses a Prelude native subject XML file into a `SubjectNative` struct.
///
/// # Example
///
Expand Down Expand Up @@ -913,7 +913,7 @@ fn extract_attributes(e: &BytesStart) -> Result<HashMap<String, String>, Error>
Ok(attrs)
}

/// Parses a Prelude native user XML file into a `UserNative` stuct.
/// Parses a Prelude native user XML file into a `UserNative` struct.
///
/// # Example
///
Expand Down Expand Up @@ -1143,7 +1143,7 @@ mod tests {
}

#[test]
fn test_site_invaid_file_type_error() {
fn test_site_invalid_file_type_error() {
let file = Builder::new()
.prefix("test")
.suffix(".csv")
Expand All @@ -1164,7 +1164,7 @@ mod tests {
}

#[test]
fn test_subject_invaid_file_type_error() {
fn test_subject_invalid_file_type_error() {
let file = Builder::new()
.prefix("test")
.suffix(".csv")
Expand All @@ -1185,7 +1185,7 @@ mod tests {
}

#[test]
fn test_user_invaid_file_type_error() {
fn test_user_invalid_file_type_error() {
let file = Builder::new()
.prefix("test")
.suffix(".csv")
Expand Down