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

Quick Param Updates #641

Merged
merged 5 commits into from
Dec 13, 2019
Merged

Quick Param Updates #641

merged 5 commits into from
Dec 13, 2019

Conversation

mpayson
Copy link
Contributor

@mpayson mpayson commented Dec 3, 2019

For #628 & #626

@codecov
Copy link

codecov bot commented Dec 3, 2019

Codecov Report

Merging #641 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@          Coverage Diff          @@
##           master   #641   +/-   ##
=====================================
  Coverage     100%   100%           
=====================================
  Files         104    104           
  Lines        1528   1528           
  Branches      261    261           
=====================================
  Hits         1528   1528
Impacted Files Coverage Δ
packages/arcgis-rest-geocoding/src/geocode.ts 100% <ø> (ø) ⬆️
packages/arcgis-rest-feature-layer/src/query.ts 100% <ø> (ø) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f52b963...204d6df. Read the comment docs.

Copy link
Contributor

@jgravois jgravois left a comment

Choose a reason for hiding this comment

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

rock n roll! 🎸

thanks for jumping in on this one @mpayson!

Comment on lines +70 to +76
geocode({
params: {
singleLine: "LAX",
countryCode: "USA",
outFields: ["Addr_type", "Score"]
}
})
Copy link
Contributor

Choose a reason for hiding this comment

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

the params object is a catch all that allows anyone to pass any parameter they want. for a test like this its more helpful to exercise the curated list and confirm we are indeed also passing through 'first class citizen' parameters appropriately.

geocode({
  singleLine: "LAX",
  countryCode: "USA",
  outFields: ["Addr_type", "Score"]
})

Copy link
Contributor Author

Choose a reason for hiding this comment

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

added another test for named parameters

const outFieldsEncoded = encodeURIComponent(
["Addr_type", "Score"].join(",")
);
expect(options.body).toContain(`outFields=${outFieldsEncoded}`);
Copy link
Contributor

Choose a reason for hiding this comment

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

very nice. 🍨

Copy link
Member

@tomwayson tomwayson left a comment

Choose a reason for hiding this comment

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

Thanks @mpayson!

@tomwayson
Copy link
Member

This is in v2.7.0

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.

None yet

3 participants