Skip to content

Conversation

oguzkocer
Copy link
Contributor

This PR dissects #46 and implements the Rust parts that still makes sense to include.

  • Improves ParsedUrl to be a proper wrapper around url::Url. The point of this type is to be able to expose it through FFI and this setup should allow us to do that. It adds all variants of url::ParseError to ParseUrlError and a Generic error because url::ParseError is non-exhaustive. It adds some unit tests to test various error types - some of which is lifted from Add Login and URL Tests #46.
  • Brings in OAuthResponseUrlError from Add Login and URL Tests #46, updating the extract_login_details_from_url implementation to return a Result. Also brings in the unit tests related to this from Add Login and URL Tests #46.

@oguzkocer oguzkocer added the Rust label Jul 4, 2024
@oguzkocer oguzkocer added this to the 0.1 milestone Jul 4, 2024
@oguzkocer oguzkocer requested a review from jkmassel July 4, 2024 17:42
Copy link
Contributor

@jkmassel jkmassel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This was super quick and easy to integrate with Swift, and the tests look solid.

Approving for now, we'll add more test cases as users do weird things to it 😂

@jkmassel jkmassel enabled auto-merge (squash) July 4, 2024 18:09
@jkmassel jkmassel merged commit 7e045b0 into trunk Jul 4, 2024
@jkmassel jkmassel deleted the extract-login-details-improvements branch July 4, 2024 18:15
@jkmassel jkmassel mentioned this pull request Jul 4, 2024
@oguzkocer oguzkocer added the Swift label Jul 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants