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

Adds Regression Test By Mocking Input #32

Merged
merged 6 commits into from
May 22, 2015
Merged

Adds Regression Test By Mocking Input #32

merged 6 commits into from
May 22, 2015

Conversation

waprin
Copy link
Contributor

@waprin waprin commented May 22, 2015

If someone checked out origin/master and ran the samples, they immediately hit a string concatenation error. While an easy fix, I generally think it's a good idea, if possible, to write a failing test that then passes along with the bug fix. This is slightly awkward when getting user input is involved, but here's a pass at it, let me know what you think.

@waprin waprin assigned waprin and theacodes and unassigned waprin May 22, 2015
@@ -48,3 +48,6 @@ def paging(service, request_func, num_retries=5, **kwargs):
has_next = False
yield response
# [END paging]

def get_input(text):
return input(text)
Copy link
Contributor

Choose a reason for hiding this comment

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

@jonparrott has an opinion on this!
input trusts the input and eval it, maybe we should just use raw_input here.

Correct me if I'm wrong.

Copy link
Contributor

Choose a reason for hiding this comment

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

@waprin is fixing it, and removing get_input all together in favor of directly mocking raw_input.

waprin added a commit that referenced this pull request May 22, 2015
Adds Regression Test By Mocking Input
@waprin waprin merged commit a2cd34b into master May 22, 2015
@theacodes theacodes deleted the regression branch August 3, 2015 18:26
m-strzelczyk pushed a commit that referenced this pull request Nov 3, 2022
- [ ] Regenerate this pull request now.

PiperOrigin-RevId: 472561635

Source-Link: googleapis/googleapis@332ecf5

Source-Link: https://github.com/googleapis/googleapis-gen/commit/4313d682880fd9d7247291164d4e9d3d5bd9f177
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNDMxM2Q2ODI4ODBmZDlkNzI0NzI5MTE2NGQ0ZTlkM2Q1YmQ5ZjE3NyJ9
dandhlee pushed a commit that referenced this pull request Nov 15, 2022
- [ ] Regenerate this pull request now.

PiperOrigin-RevId: 472561635

Source-Link: googleapis/googleapis@332ecf5

Source-Link: googleapis/googleapis-gen@4313d68
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNDMxM2Q2ODI4ODBmZDlkNzI0NzI5MTE2NGQ0ZTlkM2Q1YmQ5ZjE3NyJ9
MiaCY pushed a commit that referenced this pull request Apr 11, 2023
This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [google-cloud-scheduler](https://github.com/googleapis/python-scheduler) | major | `==1.3.0` -> `==2.0.0` |

---

### Release Notes

<details>
<summary>googleapis/python-scheduler</summary>

### [`v2.0.0`](https://github.com/googleapis/python-scheduler/blob/master/CHANGELOG.md#&#8203;200-httpswwwgithubcomgoogleapispython-schedulercomparev130v200-2020-08-27)

[Compare Source](https://github.com/googleapis/python-scheduler/compare/v1.3.0...v2.0.0)

##### ⚠ BREAKING CHANGES

-   migrate to microgenerator ([#&#8203;29](https://github.com/googleapis/python-scheduler/issues/29))

##### Features

-   migrate to microgenerator ([#&#8203;29](https://github.com/googleapis/python-scheduler/issues/29)) ([82f66ed](https://github.com/googleapis/python-scheduler/commit/82f66ed9c163b2f6597bf5661469ca9ca1bef741))

##### Bug Fixes

-   update retry configs ([#&#8203;20](https://github.com/googleapis/python-scheduler/issues/20)) ([7f82c9f](https://github.com/googleapis/python-scheduler/commit/7f82c9ffc292d72907de66bf6d5fa39e38d26085))

</details>

---

### Renovate configuration

:date: **Schedule**: At any time (no schedule defined).

:vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

:recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

:no_bell: **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/python-scheduler).
dandhlee pushed a commit that referenced this pull request Apr 22, 2023
This PR contains the following updates:

| Package | Update | Change |
|---|---|---|
| [google-cloud-scheduler](https://github.com/googleapis/python-scheduler) | major | `==1.3.0` -> `==2.0.0` |

---

### Release Notes

<details>
<summary>googleapis/python-scheduler</summary>

### [`v2.0.0`](https://github.com/googleapis/python-scheduler/blob/master/CHANGELOG.md#&#8203;200-httpswwwgithubcomgoogleapispython-schedulercomparev130v200-2020-08-27)

[Compare Source](https://github.com/googleapis/python-scheduler/compare/v1.3.0...v2.0.0)

##### ⚠ BREAKING CHANGES

-   migrate to microgenerator ([#&#8203;29](https://github.com/googleapis/python-scheduler/issues/29))

##### Features

-   migrate to microgenerator ([#&#8203;29](https://github.com/googleapis/python-scheduler/issues/29)) ([82f66ed](https://github.com/googleapis/python-scheduler/commit/82f66ed9c163b2f6597bf5661469ca9ca1bef741))

##### Bug Fixes

-   update retry configs ([#&#8203;20](https://github.com/googleapis/python-scheduler/issues/20)) ([7f82c9f](https://github.com/googleapis/python-scheduler/commit/7f82c9ffc292d72907de66bf6d5fa39e38d26085))

</details>

---

### Renovate configuration

:date: **Schedule**: At any time (no schedule defined).

:vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

:recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

:no_bell: **Ignore**: Close this PR and you won't be reminded about this update again.

---

 - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box

---

This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/python-scheduler).
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

Successfully merging this pull request may close these issues.

3 participants