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

WIP on Issue 57 extend line web api #64

Merged
merged 10 commits into from
Mar 19, 2024
Merged

Conversation

BhanuKandula5030
Copy link
Contributor

What was changed?

Updated Endpoint Logic: Refactored the GET /line/{id} endpoint in the index.js file and also updated the line.mjs file.

Database Abstraction: Introduced a database controller abstraction with db.getByID() and db.find({property: match}) methods, simulating the connection to an actual database.

Alternate Returns for Query Parameters: Implemented logic to handle query parameters such as ?text=blob, ?image=full, ?image=line, and ?lookup=project mentioned in the issue.

Functionality unit tests : Implemented the tests to ensure the different query parameters are working fine.

Database Mock: Created a simple database mock (db.js) to simulate database interactions for testing purposes.

thehabes and others added 2 commits February 14, 2024 16:32
* /manifest route prototype (#6) (#10)

* More set up for testing

* Now this is something worth bringing to the table to talk about.

* Now this is something worth bringing to the table to talk about.

* Hands up, no further until after stand up.  Make sure this is on a better looking track.

* Better organization.  Better notes and textual queues to what is going on.

* oo get that low hanging coverage

* test wording hint

* If I typed out this comment your would TLDR and move on so...here's some stuff.

* Fancy.  Tests are segregated and can be called individually or all together.

* Cleaning up

* cleanup getting ready for PR

* Documentation for sanity

Co-authored-by: Bryan Haberberger <[email protected]>

* WIP on issue 19 (#32)

* added initial code for issue19 page/id

* removed the test cases package in page/tests-not required now

* updated on the previous comments on issue

* WIP on Issue 21 (#33)

* Added the initial codebase to implement the GET/line/{lineid} and REST responses

* Added the Code Changes Documentation

* Delete Code Changes Documnetation.md

* Updated the code with the requested comments and added the end to end,exists and functionality test cases

* Added the Read me file , updated the code for the requested changes

---------

Co-authored-by: BhanuKandula5030 <[email protected]>
Co-authored-by: Bryan Haberberger <[email protected]>

* WIP on Issue 2 (#34)

* Initial commit on Issue #2, largely duplicating /manifest code to new /project directory

* /project sends local dummy JSON data

* Added tests to project directory

* Addressed comment on mockPause() in project.mjs

---------

Co-authored-by: Bryan Haberberger <[email protected]>

* Manifest endpoint cleanup (#47)

* clean it up!

* documentation

* documentation and cleanup

* documentation and cleanup

* big merge cleanup

---------

Co-authored-by: Patrick Cuba <[email protected]>
Co-authored-by: Sandeep Kumar Sutharapu <[email protected]>
Co-authored-by: BhanuKandula5030 <[email protected]>
Co-authored-by: BhanuKandula5030 <[email protected]>
Co-authored-by: Leandru Martin <[email protected]>
…he functionality unit tests to pass the different query parameters
@BhanuKandula5030 BhanuKandula5030 self-assigned this Mar 4, 2024
@BhanuKandula5030 BhanuKandula5030 linked an issue Mar 4, 2024 that may be closed by this pull request
…action of teh controller and implemented the mock test cases and addressed the end point parameters
@BhanuKandula5030 BhanuKandula5030 marked this pull request as ready for review March 18, 2024 07:26
@BhanuKandula5030 BhanuKandula5030 marked this pull request as draft March 18, 2024 17:58
@BhanuKandula5030 BhanuKandula5030 marked this pull request as ready for review March 18, 2024 18:53
Copy link
Member

@thehabes thehabes left a comment

Choose a reason for hiding this comment

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

Make sure the endpoints actually process and return the correct things for some of these parameters you are building in support for.

line/__tests__/end_to_end_unit.test.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
Copy link
Member

@cubap cubap left a comment

Choose a reason for hiding this comment

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

I don't hate it but it needs a little more attention.

line/index.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
Copy link
Member

@cubap cubap left a comment

Choose a reason for hiding this comment

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

This definitely isn't the last time we'll be through this code, so there are some things that need to be accepted as just incomplete. I would never hold back an entire PR just for semicolons, but it has gone back and forth so many times here that I am worried about your development environment/workflow.

If you don't address anything else but can confidently remove the ";" that are unneeded, I will endorse pulling this in.

line/__tests__/end_to_end_unit.test.mjs Outdated Show resolved Hide resolved
line/index.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
line/line.mjs Outdated Show resolved Hide resolved
Copy link
Member

@cubap cubap left a comment

Choose a reason for hiding this comment

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

I think we're good now.

@cubap cubap merged commit 210c3d5 into development Mar 19, 2024
3 checks passed
@thehabes thehabes deleted the 57-extend-line-web-api branch April 3, 2024 14:29
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.

Extend Line web API
5 participants