From 3c11d81577e545660accb344e664c62562948018 Mon Sep 17 00:00:00 2001 From: ryansurf Date: Sat, 1 Jun 2024 14:18:26 -0700 Subject: [PATCH 1/5] Updated tests docs --- docs/tests.md | 21 ++++++++++++++++++--- images/coverage_report.PNG | Bin 0 -> 17923 bytes 2 files changed, 18 insertions(+), 3 deletions(-) create mode 100644 images/coverage_report.PNG diff --git a/docs/tests.md b/docs/tests.md index 30c1ef1..eb379bd 100644 --- a/docs/tests.md +++ b/docs/tests.md @@ -1,8 +1,12 @@ # Tests -To run tests, install pytest, `pip install pytest` and navigate to `/test`. +Tests can be run using the `Makefile` in the root of the project -Run `pytest` +`make test` + +Alternatively, navigate to `/test` and run: + +`pytest` On a push/pull request, git will run `pytest` for you to catch any errors. @@ -12,6 +16,17 @@ In `/tests`, there are multiple files for different types of test cases. - `test_helper.py`: Tests functions in `src/helper.py` (functions like rounding decimals, etc.) - `test_api.py`: Tests functions in `src/api.py`. -- `test_server.py`: Tests the Flask server in `src/server/py` +- `test_server.py`: Tests the Flask server in `src/server.py` +- `test_gpt.py`: Tests functions server in `src/gpt.py` +- `test_cli.py`: Tests the function server in `src/cli.py` Writing tests is encouraged, especially if you introduce a new function/feature! + +## Coverage Report + +On each commit/Pull Request a coverage report should be automatically generated and posted +in the commit's comments. It is helpful to get an idea of where tests are lacking. + +

+ coverage report png +

\ No newline at end of file diff --git a/images/coverage_report.PNG b/images/coverage_report.PNG new file mode 100644 index 0000000000000000000000000000000000000000..be277f54017d902611294bce95356257a12714e2 GIT binary patch literal 17923 zcmeIacT|(x);EgVjvKI`C}X0qcz~)4qtO!O`fWrlXJkAT`n3%8azC2 z;}2}!-3@%-|3L4yFAooYEB9|ln|H~59-bSi`q~gA1CYrJ{6caNVr89m!~NZ=iGwe zgKeH;E(SIF*_G*u!=(rhky@Et_{H7-=!q|~V5q**L#u;V+Fub)!pOaJXy{N0D z4lBCa)f(l(jqb%RQZurel$1o^6GYOQ4W9cx(`ox{XlNjFPAin7IrXPL?-|t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zWG)R61-d(RZ$uSvZ|gwYK;^Cq0KZ&k6sR?CY~%*6m&_*A>advI5LG4K9_}3VT`P^R zZVq#GP`dyDy*NBA?D5(AI`EulN-LBN%GWbr0En6)~v=bg=3R}W{^`kFw8_NsKx00nl9k#zWa|U#_4>%-m?aD31Kc0S( zkjV2J=_{^j{>Sgadgwm={eKnPAFoJ&&R+iw36AC@bI>)$Ze KuF|~o^nU;b6k4nR literal 0 HcmV?d00001 From e6cb402bb135ac21ed8e94449a1e8a29f3051435 Mon Sep 17 00:00:00 2001 From: ryansurf Date: Sat, 1 Jun 2024 14:20:42 -0700 Subject: [PATCH 2/5] discord and repo widget in docs --- docs/index.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/index.md b/docs/index.md index fb80041..c64525f 100644 --- a/docs/index.md +++ b/docs/index.md @@ -2,3 +2,8 @@ cli-surf is a simple command line tool (with a frontend too!) that sends custom ocean/surf report data! + + + +[![ReadMe Card](https://github-readme-stats.vercel.app/api/pin/?username=ryansurf&repo=cli-surf)](https://github.com/ryansurf/cli-surf) \ No newline at end of file From bab8152e7fce0e3081bc716dff4f7f71064abf85 Mon Sep 17 00:00:00 2001 From: ryansurf Date: Sat, 1 Jun 2024 14:45:08 -0700 Subject: [PATCH 3/5] cheat cheat addition in docs --- docs/cheat_sheet.md | 37 +++++++++++++++++++++++++++++++++++++ mkdocs.yml | 1 + 2 files changed, 38 insertions(+) create mode 100644 docs/cheat_sheet.md diff --git a/docs/cheat_sheet.md b/docs/cheat_sheet.md new file mode 100644 index 0000000..d6ba90b --- /dev/null +++ b/docs/cheat_sheet.md @@ -0,0 +1,37 @@ +# Cheat Sheet! + +When developing, these commands may come in handy: + +## Terminal commands + +| Argument | Description| +| -------- | ------- | +| `sudo ss -lptn 'sport = :` | List the processes running on port ``. | +| `sudo kill -9 ` | Kill the process with with id `` | + +## [Poetry Commands](https://python-poetry.org/docs/basic-usage/) + +| Argument | Description| +| -------- | ------- | +| `poetry install` | Install project dependencies | +| `poetry shell` | Activate the virtual environment | +| `poetry add ` | Add a new dependency to Poetry | +| `poetry add --group dev ` | Add a new developer dependency to Poetry | +| `poetry show` | List all available packages with descriptions | + +## [Mkdocs Commands](https://www.mkdocs.org/user-guide/) + +| Argument | Description| +| -------- | ------- | +| `mkdocs serve` | Creates dev-server that lets your preview the docs as you change them. | + +## [Make Commands]("https://github.com/ryansurf/cli-surf/blob/main/makefile") + +| Argument | Description| +| -------- | ------- | +| `make run` | Runs `server.py` | +| `make run_docker` | Runs `docker compose up -d` | +| `make test` | Runs pytest | +| `make test_docker` | Runs pytest on Docker | +| `make output_coverage` | Outputs the coverage of the tests | +| `make send_email` | Runs `send_email.py` | \ No newline at end of file diff --git a/mkdocs.yml b/mkdocs.yml index 8c96aaf..b39f0e5 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -41,6 +41,7 @@ nav: - Styling: styling.md - Tests: tests.md - Structure: structure.md + - Cheat Sheet: cheat_sheet.md From 0d949c1a6df06a4dc72918c27aa5d9dd62a3c496 Mon Sep 17 00:00:00 2001 From: ryansurf Date: Sat, 1 Jun 2024 14:48:01 -0700 Subject: [PATCH 4/5] project structure update in docs --- docs/structure.md | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-) diff --git a/docs/structure.md b/docs/structure.md index a2e74a7..098f5e1 100644 --- a/docs/structure.md +++ b/docs/structure.md @@ -24,9 +24,12 @@ The basic structure of the project is: More in-depth structure: ``` +. +├── compose.yaml ├── CONTRIBUTING.md ├── Dockerfile ├── docs +│ ├── cheat_sheet.md │ ├── faq.md │ ├── index.md │ ├── install.md @@ -36,28 +39,38 @@ More in-depth structure: │ └── tests.md ├── help.txt ├── images +│ ├── cli.gif +│ ├── coverage_report.PNG │ ├── ocean.gif -│ ├── surf.gif +│ ├── old_cli.gif │ ├── wave.png │ └── website.gif +├── makefile ├── mkdocs.yml +├── poetry.lock ├── pyproject.toml ├── README.md -├── requirements.txt ├── src │ ├── api.py │ ├── art.py │ ├── cli.py +│ ├── gpt.py │ ├── helper.py │ ├── __init__.py │ ├── __pycache__ │ ├── send_email.py │ ├── server.py +│ ├── settings.py │ ├── static │ └── templates ├── start_venv.sh -├── tests +└── tests ├── __init__.py - └── test_code.py + ├── __pycache__ + ├── test_api.py + ├── test_cli.py + ├── test_gpt.py + ├── test_helper.py + └── test_server.py ``` From 2f6361ac54591615e4a415e9e6741939cc63e5fe Mon Sep 17 00:00:00 2001 From: ryansurf Date: Sat, 1 Jun 2024 15:06:23 -0700 Subject: [PATCH 5/5] cheat sheet git instructions --- docs/cheat_sheet.md | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/docs/cheat_sheet.md b/docs/cheat_sheet.md index d6ba90b..1b90bd4 100644 --- a/docs/cheat_sheet.md +++ b/docs/cheat_sheet.md @@ -17,7 +17,7 @@ When developing, these commands may come in handy: | `poetry shell` | Activate the virtual environment | | `poetry add ` | Add a new dependency to Poetry | | `poetry add --group dev ` | Add a new developer dependency to Poetry | -| `poetry show` | List all available packages with descriptions | +| `poetry show` | List all available dependencies with descriptions | ## [Mkdocs Commands](https://www.mkdocs.org/user-guide/) @@ -34,4 +34,19 @@ When developing, these commands may come in handy: | `make test` | Runs pytest | | `make test_docker` | Runs pytest on Docker | | `make output_coverage` | Outputs the coverage of the tests | -| `make send_email` | Runs `send_email.py` | \ No newline at end of file +| `make send_email` | Runs `send_email.py` | + + +## [Git](https://education.github.com/git-cheat-sheet-education.pdf) + +| Argument | Description| +| -------- | ------- | +| `git clone ` | Clones git repository to your local machine| +| `git add ` | Adds file to your next commit | +| `git commit -m ` | Commit your staged content (from `git add `) | +| `git push` | Pushes lcoal changes to remote repo branch | +| `git status` | Shows modified files | +| `git branch` | Shows the branches | +| `git checkout -b ` | Creates a new branch, `branch`, and switches into it | +| `git branch -d ` | Delete a local branch | +| `git push -u origin ` | Pushes a local branch to the upstream remote repo | \ No newline at end of file