smartcar / node-sdk

Smartcar Node.js SDK
MIT License
50 stars 14 forks source link

feat(vehicle): get & set charge limit #161

Closed EvanPeterson1324 closed 1 year ago

EvanPeterson1324 commented 1 year ago

Overview

Adds two new functions to the vehicle object, getChargeLimit and setChargeLimit

Asana: https://app.asana.com/0/1204073873904879/1204302264096972/f

Dependency additions

Checklist

codecov[bot] commented 1 year ago

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.01 :tada:

Comparison is base (230e41e) 99.59% compared to head (2356efe) 99.60%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #161 +/- ## ========================================== + Coverage 99.59% 99.60% +0.01% ========================================== Files 6 6 Lines 246 253 +7 ========================================== + Hits 245 252 +7 Misses 1 1 ``` | [Impacted Files](https://codecov.io/gh/smartcar/node-sdk/pull/161?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=smartcar) | Coverage Δ | | |---|---|---| | [lib/vehicle.js](https://codecov.io/gh/smartcar/node-sdk/pull/161?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=smartcar#diff-bGliL3ZlaGljbGUuanM=) | `100.00% <100.00%> (ø)` | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=smartcar). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=smartcar)

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

EvanPeterson1324 commented 1 year ago

Trying to figure out why charge/limit is returning a validation error for setChargeLimit(.9) in the E2E tests.

Need to figure out how to get the E2E tests running locally

nbry commented 1 year ago

RE: Running tests locally

To run tests locally, you will need geckodriver installed. One way to do this is to do a global install using npm:

https://www.npmjs.com/package/geckodriver

Then, execute the following in your shell.

E2E_SMARTCAR_CLIENT_ID="replace-with-your-client-id" E2E_SMARTCAR_CLIENT_SECRET="replace-with-your-client-secret" E2E_SMARTCAR_REDIRECT_URI="replace-with-your-redirect-uri" HEADLESS=true npm test

Replace all values with your own credentials. If you'd like to borrow mine, I can Slack it to you

EvanPeterson1324 commented 1 year ago

Will make certain to squash merge!

smartcar-ci commented 1 year ago

:tada: This PR is included in version 9.4.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket: