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

docs(ngMock/angular-mocks) added response to whenPOST mock #6761

Closed
wants to merge 2 commits into from
Closed

docs(ngMock/angular-mocks) added response to whenPOST mock #6761

wants to merge 2 commits into from

Conversation

sorenlouv
Copy link
Contributor

Request Type: docs

How to reproduce: Use whenPOST without returning a response

Component(s): ngMocks

Impact: small

Complexity: small

This issue is related to: whenPOST (mocking)

Detailed Description: The whenPOST method should return a response containing status, response body and headers. If omitted the following error will be thrown:

Uncaught TypeError: Cannot read property '2' of undefined

The documentation doesn't make it very clear, so I think it will be appropriate to add.

The  ```whenPOST``` method should return a response object containing status, response body and headers. If omitted the following error will be thrown:

```Uncaught TypeError: Cannot read property '2' of undefined```

The documentation doesn't make it very clear, so I think it will be appropriate to add it here.
@mary-poppins
Copy link

Thanks for the PR! Please check the items below to help us merge this faster. See the contributing docs for more information.

  • Uses the issue template (#6761)

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!

@sorenlouv sorenlouv changed the title Added response to whenPOST mock docs(ngMock/angular-mocks) added response to whenPOST mock Mar 20, 2014
@lefos987 lefos987 added this to the Backlog milestone Mar 20, 2014
@mary-poppins
Copy link

I'm sorry, but I wasn't able to verify your Contributor License Agreement (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 us 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.

1 similar comment
@mary-poppins
Copy link

I'm sorry, but I wasn't able to verify your Contributor License Agreement (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 us 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.

@sorenlouv
Copy link
Contributor Author

Hi @caitp
Anything I can do to get this PR resolved?

@caitp
Copy link
Contributor

caitp commented Apr 24, 2014

I can merge this later today, I'm not sure why it's triaged the way it is though.

I worry that this feature might end up removed at some point though, since it isn't being used in any of the core tests. I dunno.

caitp pushed a commit that referenced this pull request Apr 24, 2014
… 1st param

The  `whenPOST` method should return a response object containing status, response body and headers.
If omitted the following error will be thrown:

`Uncaught TypeError: Cannot read property '2' of undefined`

The documentation doesn't make it very clear, so I think it will be appropriate to add it here.

Closes #6761
@caitp caitp closed this in e19dbc7 Apr 24, 2014
@sorenlouv sorenlouv deleted the patch-1 branch May 19, 2014 14:42
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