Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add me-central-1 and il-central-1 to rusoto_signature::Region #2010

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
14 changes: 14 additions & 0 deletions rusoto/signature/src/region.rs
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,12 @@ pub enum Region {
/// Region that covers Southern Europe
EuSouth1,

// Tel Aviv, Israel Central
IlCentral1,

/// Dubai, Middle East Central
MeCentral1,

/// Bahrain, Middle East South
MeSouth1,

Expand Down Expand Up @@ -155,6 +161,8 @@ impl Region {
Region::EuWest3 => "eu-west-3",
Region::EuNorth1 => "eu-north-1",
Region::EuSouth1 => "eu-south-1",
Region::IlCentral1 => "il-central-1",
Region::MeCentral1 => "me-central-1",
Region::MeSouth1 => "me-south-1",
Region::SaEast1 => "sa-east-1",
Region::UsEast1 => "us-east-1",
Expand Down Expand Up @@ -256,6 +264,8 @@ impl FromStr for Region {
"eu-west-3" | "euwest3" => Ok(Region::EuWest3),
"eu-north-1" | "eunorth1" => Ok(Region::EuNorth1),
"eu-south-1" | "eusouth1" => Ok(Region::EuSouth1),
"il-central-1" | "ilcentral1" => Ok(Region::IlCentral1),
"me-central-1" | "mecentral1" => Ok(Region::MeSouth1),
"me-south-1" | "mesouth1" => Ok(Region::MeSouth1),
"sa-east-1" | "saeast1" => Ok(Region::SaEast1),
"us-east-1" | "useast1" => Ok(Region::UsEast1),
Expand Down Expand Up @@ -332,6 +342,8 @@ mod tests {
assert_eq!("eu-west-3".parse(), Ok(Region::EuWest3));
assert_eq!("eu-north-1".parse(), Ok(Region::EuNorth1));
assert_eq!("eu-south-1".parse(), Ok(Region::EuSouth1));
assert_eq!("il-central-1".parse(), Ok(Region::IlCentral1));
assert_eq!("me-central-1".parse(), Ok(Region::MeCentral1));
assert_eq!("me-south-1".parse(), Ok(Region::MeSouth1));
assert_eq!("sa-east-1".parse(), Ok(Region::SaEast1));
assert_eq!("us-east-1".parse(), Ok(Region::UsEast1));
Expand Down Expand Up @@ -362,6 +374,8 @@ mod tests {
assert_tokens(&Region::EuWest3, &tokens_for_region("eu-west-3"));
assert_tokens(&Region::EuNorth1, &tokens_for_region("eu-north-1"));
assert_tokens(&Region::EuSouth1, &tokens_for_region("eu-south-1"));
assert_tokens(&Region::IlCentral1, &tokens_for_region("il-central-1"));
assert_tokens(&Region::MeCentral1, &tokens_for_region("me-central-1"));
assert_tokens(&Region::MeSouth1, &tokens_for_region("me-south-1"));
assert_tokens(&Region::SaEast1, &tokens_for_region("sa-east-1"));
assert_tokens(&Region::UsEast1, &tokens_for_region("us-east-1"));
Expand Down