Code Monkey home page Code Monkey logo

cathay_sqa_python's Introduction

Cathay_SQA_Python

Problem 1's Test Cases

假設這位客戶customer:name是"Test User"、account為"100-1100",一開始帳戶會先存100元,要測試下面項目:
https://github.com/LeBronWilly/Cathay_SQA_Python/tree/main/tests/Problem%201

  1. Test Case1:之後存款 1000 元, 確認帳戶總金額為 1100 元
  2. Test Case2:下一步提款 500 元, 確認帳戶總金額為 600 元
  3. Test Case3:假設銀行年利率是10%, 經過一年之後確認帳戶餘額為660元
  4. Test Case4:之後提款 700 元, pytest 預期會接到 RuntimeError

Problem 2's Test Cases

https://github.com/LeBronWilly/Cathay_SQA_Python/tree/main/tests/Problem%202

  1. Test Case1:使用 Python 抓取 https://cathay-ds-test.s3-ap-northeast-1.amazonaws.com/user_info?userid=A123456789 ,並利用 assert 確認 http response status code 為 200
  2. Test Case2:使用 Python 抓取 https://cathay-ds-test.s3-ap-northeast-1.amazonaws.com/company_info?companyid=1 ,並利用 assert 確認 http response status code 為 403

Bonus

https://github.com/LeBronWilly/Cathay_SQA_Python/tree/main/.github/workflows
請運用GitHub Actions或其他CI Services自動執行測試

Run Pytest

cls
cd /d D:
cd D:\GitHub\Cathay_SQA_Python
pytest -W ignore::DeprecationWarning -v

Some Docs

https://github.com/LeBronWilly/Cathay_SQA_Python/tree/main/docs

  1. 題目的PPT檔(Take-home-exam.pptx)
  2. 結果截圖的Word檔(Solutions.docx)
  3. GitHub Actions執行完的Logs

Some References

  1. https://myapollo.com.tw/zh-tw/pytest/
  2. https://blog.cti.app/archives/20220
  3. https://zwindr.blogspot.com/2019/01/python-pytest.html
  4. https://www.796t.com/article.php?id=164187
  5. https://iter01.com/504335.html
  6. https://docs.pytest.org/en/latest/how-to/fixtures.html
  7. https://stackoverflow.com/questions/39395731/testing-class-methods-with-pytest/39395889
  8. https://kirin.idv.tw/python-decimal-module-tutorial/
  9. https://www.maxlist.xyz/2019/12/12/python-oop/
  10. https://www.learncodewithmike.com/2020/01/python-inheritance.html
  11. https://stackoverflow.com/questions/40710094/how-to-suppress-py-test-internal-deprecation-warnings
  12. https://github.com/LeBronWilly/Basic_Web_Crawler/blob/master/Web%20Scraper.ipynb
  13. https://stackoverflow.com/questions/55944961/python-403-access-denied-when-post-request
  14. https://ithelp.ithome.com.tw/articles/10191165
  15. https://www.learncodewithmike.com/2020/09/7-tips-to-avoid-getting-blocked-while-scraping.html
  16. https://stackoverflow.com/questions/60298449/github-action-with-pytest
  17. https://www.linkedin.com/pulse/test-automation-how-build-cicd-pipeline-using-pytest-nir-tal/
  18. https://kknews.cc/zh-tw/code/zr5km6a.html
  19. https://blog.dennisokeeffe.com/blog/2021-08-08-pytest-with-github-actions
  20. https://iter01.com/608520.html

cathay_sqa_python's People

Contributors

lebronwilly avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.