Skip to content

Commit

Permalink
fmt and makefile fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
nichmorgan committed Oct 19, 2023
1 parent 8b03bf3 commit 6900c7c
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 17 deletions.
1 change: 1 addition & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ check-event-features:
cargo test --package aws_lambda_events --no-default-features --features sns
cargo test --package aws_lambda_events --no-default-features --features sqs
cargo test --package aws_lambda_events --no-default-features --features streams
cargo test --package aws_lambda_events --no-default-features --features documentdb

fmt:
cargo +nightly fmt --all
2 changes: 1 addition & 1 deletion lambda-events/src/event/documentdb/events/commom_types.rs
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ pub struct InnerTimestamp {
pub struct Timestamp {
#[serde(rename = "$timestamp")]
pub timestamp: InnerTimestamp,
}
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
use serde::{Deserialize, Serialize};

use super::commom_types::{DocumentId, Timestamp, DatabaseCollection, AnyDocument};

use super::commom_types::{AnyDocument, DatabaseCollection, DocumentId, Timestamp};

#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
#[serde(rename_all = "camelCase")]
Expand Down
2 changes: 1 addition & 1 deletion lambda-events/src/event/documentdb/events/mod.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
pub mod commom_types;
pub mod delete_event;
pub mod drop_event;
pub mod drop_database_event;
pub mod drop_event;
pub mod insert_event;
pub mod invalidate_event;
pub mod rename_event;
Expand Down
2 changes: 1 addition & 1 deletion lambda-events/src/event/documentdb/events/update_event.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
use serde::{Deserialize, Serialize};

use super::commom_types::{AnyDocument, DocumentId, DocumentKeyId, DatabaseCollection, Timestamp};
use super::commom_types::{AnyDocument, DatabaseCollection, DocumentId, DocumentKeyId, Timestamp};

#[derive(Clone, Debug, Default, Deserialize, Eq, PartialEq, Serialize)]
#[serde(rename_all = "camelCase")]
Expand Down
23 changes: 11 additions & 12 deletions lambda-events/src/event/documentdb/mod.rs
Original file line number Diff line number Diff line change
@@ -1,14 +1,9 @@
pub mod events;

use self::events::{
delete_event::ChangeDeleteEvent,
drop_event::ChangeDropEvent,
insert_event::ChangeInsertEvent,
invalidate_event::ChangeInvalidateEvent,
replace_event::ChangeReplaceEvent,
update_event::ChangeUpdateEvent,
rename_event::ChangeRenameEvent,
drop_database_event::ChangeDropDatabaseEvent,
delete_event::ChangeDeleteEvent, drop_database_event::ChangeDropDatabaseEvent, drop_event::ChangeDropEvent,
insert_event::ChangeInsertEvent, invalidate_event::ChangeInvalidateEvent, rename_event::ChangeRenameEvent,
replace_event::ChangeReplaceEvent, update_event::ChangeUpdateEvent,
};
use serde::{Deserialize, Serialize};

Expand Down Expand Up @@ -57,7 +52,7 @@ mod test {

#[test]
fn example_documentdb_insert_event() {
test_example(include_bytes!( "../../fixtures/example-documentdb-insert-event.json"));
test_example(include_bytes!("../../fixtures/example-documentdb-insert-event.json"));
}

#[test]
Expand Down Expand Up @@ -87,11 +82,15 @@ mod test {

#[test]
fn example_documentdb_invalidate_event() {
test_example(include_bytes!("../../fixtures/example-documentdb-invalidate-event.json"));
test_example(include_bytes!(
"../../fixtures/example-documentdb-invalidate-event.json"
));
}

#[test]
fn example_documentdb_drop_database_event(){
test_example(include_bytes!("../../fixtures/example-documentdb-drop-database-event.json"));
fn example_documentdb_drop_database_event() {
test_example(include_bytes!(
"../../fixtures/example-documentdb-drop-database-event.json"
));
}
}

0 comments on commit 6900c7c

Please sign in to comment.