Skip to content
This repository has been archived by the owner on Apr 12, 2024. It is now read-only.

feat(ngMock.$httpBackend): added support for function as URL matcher #4580

Closed
wants to merge 1 commit into from

Conversation

caiotoon
Copy link
Contributor

It's now possible to pass a function to match the URL in $httpBackend mocked
expectations. This gives a more sophisticate control over the URL matching
without requiring complex RegExp mantainance or the workaround of creating
an object with a test function in order to mimic RegExp interface. Docs
were also updated.

This approach was suggested in this thread

It's now possible to pass a function to match the URL in $httpBackend
mocked
expectations. This gives a more sophisticate control over the URL
matching
without requiring complex RegExp mantainance or the workaround of
creating
an object with a `test` function in order to mimic RegExp interface.
Docs
were also updated.

This approach was suggested in [this
thread](https://groups.google.com/d/msg/angular/3QsCUEvvxlM/Q4C4ZIqNIuEJ)
@mary-poppins
Copy link

Thanks for the PR!

  • Contributor signed CLA now or in the past
    • If you just signed, leave a comment here with your real name
  • PR's commit messages follow the commit message format

If you need to make changes to your pull request, you can update the commit with git commit --amend.
Then, update the pull request with git push -f.

Thanks again for your help!

@caiotoon
Copy link
Contributor Author

Just to let you know that most of the changes to ngMock file relate to the Docs, the only line that really matters is 1553. Also I've already signed the CLA for past PRs.

@itamarkalimi
Copy link

Nics

@IgorMinar
Copy link
Contributor

I'm sorry, but I wasn't able to verify your CLA signature. CLA signature is required for any code contributions to AngularJS.

Please sign our CLA and ensure that the CLA signature email address and the email address in this PR's commits match.

If you signed the CLA as a corporation, please let me know the company's name.

Thanks a bunch!

PS: If you signed the CLA in the past then most likely the email addresses don't match. Please sign the CLA again or update the email address in the commit of this PR.
PS2: If you are a Googler, please sign the CLA as well to simplify the CLA verification process.

@caiotoon
Copy link
Contributor Author

caiotoon commented Dec 9, 2013

You're right. The previous PR was from a different email. Just signed.

PS2: I'm not :)

@IgorMinar
Copy link
Contributor

I'm sorry, but I wasn't able to verify your CLA signature. CLA signature is required for any code contributions to AngularJS.

Please sign our CLA and ensure that the CLA signature email address and the email address in this PR's commits match.

If you signed the CLA as a corporation, please let me know the company's name.

Thanks a bunch!

PS: If you signed the CLA in the past then most likely the email addresses don't match. Please sign the CLA again or update the email address in the commit of this PR.
PS2: If you are a Googler, please sign the CLA as well to simplify the CLA verification process.

@caiotoon
Copy link
Contributor Author

I've signed the first time you posted this message. Are you still unable to find my CLA? I signed again, just in case.

@IgorMinar
Copy link
Contributor

@caiotoon the email addresses don't match. can you change your commit or sign the cla with the same email as the one in the current commit?

@caiotoon
Copy link
Contributor Author

Sorry, maybe I'm missing something.

I double check the commit e-mail and It seems to be the same one at my GitHub public profile: opensource at my-username.com, right? (got from git log 5bd32b4)

I've signed using the same e-mail. Do you think it could take some days to the CLA signature to be processed? Is there anything else I could try?

@caiotoon
Copy link
Contributor Author

Hi @IgorMinar. Any news on this one? Do you think it would worth creating a new PR, trying to sign the CLA again? Anything I could help with?

@caiotoon
Copy link
Contributor Author

caiotoon commented Feb 5, 2014

@IgorMinar I've subimitted the application by email a couple of days ago. Would you please check if you can verify it again?

@caiotoon caiotoon added cla: no and removed cla: yes labels Feb 19, 2014
@IgorMinar
Copy link
Contributor

the problem is that you signed CLA with caio at caiotoon.com and your commits are authored with opensource at caiotoon.com. Because of this difference, the robot is not able to verify your CLA signature.

@caiotoon
Copy link
Contributor Author

Same problem as I had in the other thread. I've signed with both mentioned e-mails, as explained here.

Just did it once more for this e-mail. I'm sorry for the inconvenient, will commit with the former e-mail from now on.

If the CLA still doesn't show, I'd appreciate some help, as I've already signed it even via scanning and emailing.

@caiotoon
Copy link
Contributor Author

Additionally, if you want, I can drop this PR and recreate it with the former e-mail.

@IgorMinar IgorMinar closed this in d6cfcac Mar 18, 2014
@IgorMinar
Copy link
Contributor

landed in master. thanks

@caiotoon caiotoon deleted the ngMock-url-function-match branch March 18, 2014 22:35
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants