Skip to content

Relative302Test could be failed in some countries #246

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

Closed
carryel opened this issue Mar 9, 2013 · 3 comments
Closed

Relative302Test could be failed in some countries #246

carryel opened this issue Mar 9, 2013 · 3 comments
Assignees
Milestone

Comments

@carryel
Copy link
Contributor

carryel commented Mar 9, 2013

When I ran test cases locally, I met the Relative302Test failure(both Netty and Grizzly provider).

Relative302Test#redirected302Test would redirect "http://www.google.com/".
The uri would be redirected into "http://www.google.co.kr" in South Korea.

  1. Testcase's regular expression "http://www.google.[a-z]{1,}:80" was not matched at this case.
  2. "."(dot) mean "any single character" in regular expression so "http://www6google,com:80" could be also matched. This is trivial. :)
@carryel
Copy link
Contributor Author

carryel commented Mar 9, 2013

I proposed the following patch.

carryel@7204f93

In api/src/test/java/com/ning/http/client/async/Relative302Test.java
...
//String anyGoogleSubdomain = "http://www.google.[a-z]{1,}:80";
String anyGoogleSubdomain = "http://www\.google\.[a-z]+(\.[a-z]+)*:80";
...

@jfarcand
Copy link
Contributor

jfarcand commented Mar 9, 2013

Do a pull request!!! Thanks!

jfarcand pushed a commit that referenced this issue Mar 9, 2013
@carryel
Copy link
Contributor Author

carryel commented Mar 9, 2013

Thanks a lot, Jeanfrancois.

Surely I will do a pull request next time!! (I am sorry that I don't have much experience in using pull requests) :(

slandelle pushed a commit that referenced this issue Mar 10, 2013
@ghost ghost assigned rlubke Mar 11, 2013
cs-workco pushed a commit to cs-workco/async-http-client that referenced this issue Apr 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants