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

🎉 Source Pipedrive: Add unit tests #11443

Closed
wants to merge 3 commits into from
Closed

🎉 Source Pipedrive: Add unit tests #11443

wants to merge 3 commits into from

Conversation

itaseskii
Copy link
Contributor

@itaseskii itaseskii commented Mar 25, 2022

What

Adds unit tests to the Pipedrive source connector

Closes #12225.

How

Using pytest

Recommended reading order

  1. x.java
  2. y.python

🚨 User Impact 🚨

No breaking changes

Pre-merge Checklist

Expand the relevant checklist and delete the others.

New Connector

Community member or Airbyter

  • Community member? Grant edit access to maintainers (instructions)
  • Secrets in the connector's spec are annotated with airbyte_secret
  • Unit & integration tests added and passing. Community members, please provide proof of success locally e.g: screenshot or copy-paste unit, integration, and acceptance test output. To run acceptance tests for a Python connector, follow instructions in the README. For java connectors run ./gradlew :airbyte-integrations:connectors:<name>:integrationTest.
  • Code reviews completed
  • Documentation updated
    • Connector's README.md
    • Connector's bootstrap.md. See description and examples
    • docs/SUMMARY.md
    • docs/integrations/<source or destination>/<name>.md including changelog. See changelog example
    • docs/integrations/README.md
    • airbyte-integrations/builds.md
  • PR name follows PR naming conventions

Airbyter

If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.

  • Create a non-forked branch based on this PR and test the below items on it
  • Build is successful
  • If new credentials are required for use in CI, add them to GSM. Instructions.
  • /test connector=connectors/<name> command is passing
  • New Connector version released on Dockerhub by running the /publish command described here
  • After the connector is published, connector added to connector index as described here
  • Seed specs have been re-generated by building the platform and committing the changes to the seed spec files, as described here
Updating a connector

Community member or Airbyter

  • Grant edit access to maintainers (instructions)
  • Secrets in the connector's spec are annotated with airbyte_secret
  • Unit & integration tests added and passing. Community members, please provide proof of success locally e.g: screenshot or copy-paste unit, integration, and acceptance test output. To run acceptance tests for a Python connector, follow instructions in the README. For java connectors run ./gradlew :airbyte-integrations:connectors:<name>:integrationTest.
  • Code reviews completed
  • Documentation updated
    • Connector's README.md
    • Connector's bootstrap.md. See description and examples
    • Changelog updated in docs/integrations/<source or destination>/<name>.md including changelog. See changelog example
  • PR name follows PR naming conventions

Airbyter

If this is a community PR, the Airbyte engineer reviewing this PR is responsible for the below items.

  • Create a non-forked branch based on this PR and test the below items on it
  • Build is successful
  • If new credentials are required for use in CI, add them to GSM. Instructions.
  • /test connector=connectors/<name> command is passing
  • New Connector version released on Dockerhub by running the /publish command described here
  • After the new connector version is published, connector version bumped in the seed directory as described here
  • Seed specs have been re-generated by building the platform and committing the changes to the seed spec files, as described here
Connector Generator
  • Issue acceptance criteria met
  • PR name follows PR naming conventions
  • If adding a new generator, add it to the list of scaffold modules being tested
  • The generator test modules (all connectors with -scaffold in their name) have been updated with the latest scaffold by running ./gradlew :airbyte-integrations:connector-templates:generator:testScaffoldTemplates then checking in your changes
  • Documentation which references the generator is updated as needed

Tests

Unit

Put your unit tests output here.

Integration

Put your integration tests output here.

Acceptance

Put your acceptance tests output here.

@CLAassistant
Copy link

CLAassistant commented Mar 25, 2022

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 2 committers have signed the CLA.

✅ itaseskii
❌ itaseski


itaseski seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.

@github-actions github-actions bot added the area/connectors Connector related issues label Mar 25, 2022
@itaseskii
Copy link
Contributor Author

Screenshot_15

@itaseskii itaseskii changed the title add pipedrive unit tests tada Source Pipedrive: Add unit tests Mar 27, 2022
@itaseskii itaseskii changed the title tada Source Pipedrive: Add unit tests 🎉 Source Pipedrive: Add unit tests Mar 27, 2022
@lgomezm
Copy link
Contributor

lgomezm commented Mar 29, 2022

@itaseskii These changes look good to me. Thank you for the contribution.

@itaseskii
Copy link
Contributor Author

Hey @marcosmarxm can we get this reviewed? :)

@marcosmarxm
Copy link
Member

oh sure! we missed this because was without the community label. @harshithmullapudi can you take a look on this?

@harshithmullapudi
Copy link
Contributor

Hey @itaseskii can you sign the CLA

@harshithmullapudi
Copy link
Contributor

/test connector=connectors/source-pipedrive

@itaseskii
Copy link
Contributor Author

Hey @itaseskii can you sign the CLA

Hey @harshithmullapudi I have signed the CLA with my correct and existing account. I have also test covered the streams added in #11870

@harshithmullapudi
Copy link
Contributor

harshithmullapudi commented May 4, 2022

/test connector=source-pipedrive

🕑 source-pipedrive https://github.com/airbytehq/airbyte/actions/runs/2268730275
✅ source-pipedrive https://github.com/airbytehq/airbyte/actions/runs/2268730275
Python tests coverage:

Name                                                 Stmts   Miss  Cover
------------------------------------------------------------------------
source_acceptance_test/utils/__init__.py                 6      0   100%
source_acceptance_test/tests/__init__.py                 4      0   100%
source_acceptance_test/__init__.py                       2      0   100%
source_acceptance_test/tests/test_full_refresh.py       52      2    96%
source_acceptance_test/utils/asserts.py                 37      2    95%
source_acceptance_test/config.py                        74      6    92%
source_acceptance_test/utils/json_schema_helper.py     105     13    88%
source_acceptance_test/utils/common.py                  80     17    79%
source_acceptance_test/utils/compare.py                 62     23    63%
source_acceptance_test/tests/test_core.py              285    106    63%
source_acceptance_test/base.py                          10      4    60%
source_acceptance_test/utils/connector_runner.py       110     48    56%
source_acceptance_test/tests/test_incremental.py        69     38    45%
------------------------------------------------------------------------
TOTAL                                                  896    259    71%
Name                           Stmts   Miss  Cover
--------------------------------------------------
source_pipedrive/__init__.py       2      0   100%
source_pipedrive/source.py        36      2    94%
source_pipedrive/streams.py       77      8    90%
--------------------------------------------------
TOTAL                            115     10    91%

@harshithmullapudi
Copy link
Contributor

Hey @itaseskii looks like your first commit is from another account can you either change the commit or sign from that account also?

@itaseskii
Copy link
Contributor Author

Hey @itaseskii looks like your first commit is from another account can you either change the commit or sign from that account also?

@harshithmullapudi Unfortunately I can't sign it from that account since it is a non existing account on Github. The same has happened in #11878 and we have merged it as it is :)

@harshithmullapudi
Copy link
Contributor

harshithmullapudi commented May 16, 2022

/test connector=source-pipedrive

🕑 source-pipedrive https://github.com/airbytehq/airbyte/actions/runs/2331236153
✅ source-pipedrive https://github.com/airbytehq/airbyte/actions/runs/2331236153
Python tests coverage:

Name                                                 Stmts   Miss  Cover
------------------------------------------------------------------------
source_acceptance_test/utils/__init__.py                 6      0   100%
source_acceptance_test/tests/__init__.py                 4      0   100%
source_acceptance_test/__init__.py                       2      0   100%
source_acceptance_test/tests/test_full_refresh.py       52      2    96%
source_acceptance_test/utils/asserts.py                 37      2    95%
source_acceptance_test/config.py                        74      6    92%
source_acceptance_test/utils/json_schema_helper.py     105     13    88%
source_acceptance_test/utils/common.py                  80     17    79%
source_acceptance_test/utils/compare.py                 62     23    63%
source_acceptance_test/tests/test_core.py              285    106    63%
source_acceptance_test/base.py                          10      4    60%
source_acceptance_test/utils/connector_runner.py       110     48    56%
source_acceptance_test/tests/test_incremental.py        69     38    45%
------------------------------------------------------------------------
TOTAL                                                  896    259    71%
Name                           Stmts   Miss  Cover
--------------------------------------------------
source_pipedrive/__init__.py       2      0   100%
source_pipedrive/source.py        36      2    94%
source_pipedrive/streams.py       77      8    90%
--------------------------------------------------
TOTAL                            115     10    91%

@harshithmullapudi
Copy link
Contributor

harshithmullapudi commented May 16, 2022

/publish connector=connectors/source-pipedrive auto-bump-version=false

🕑 connectors/source-pipedrive https://github.com/airbytehq/airbyte/actions/runs/2331294200
❌ Failed to publish connectors/source-pipedrive

@harshithmullapudi
Copy link
Contributor

closing this in favour of #12867

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Test Coverage
5 participants