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

Add test case for Object Set using uint32 as key #1130

Merged
merged 1 commit into from
Feb 18, 2022
Merged

Conversation

meixg
Copy link
Member

@meixg meixg commented Feb 9, 2022

This PR covered template void Set(uint32_t index, const ValueType& value)
Other testings for Object (#936) may have already been covered:

https://github.com/nodejs/node-addon-api/blob/main/test/object/object.cc#L234:
PropertyLValuestd::string operator [](const char* utf8name)
PropertyLValuestd::string operator [](const std::string& utf8name)
PropertyLValue<uint32_t> operator [](uint32_t index)
Object::PropertyLValue (Uncovered)

https://github.com/nodejs/node-addon-api/blob/main/test/object/has_property.cc#L26:
bool Has(uint32_t index) const

https://github.com/nodejs/node-addon-api/blob/main/test/object/get_property.cc#L18:
Value Get(uint32_t index) const

https://github.com/nodejs/node-addon-api/blob/main/test/object/delete_property.cc#L6:
bool Delete(uint32_t index)

https://github.com/nodejs/node-addon-api/blob/main/test/object/object.cc#L280:
bool InstanceOf(const Function& constructor) const

Copy link
Member

@JckXia JckXia left a comment

Choose a reason for hiding this comment

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

LGTM!

test/object/set_property.cc Show resolved Hide resolved
@meixg
Copy link
Member Author

meixg commented Feb 17, 2022

My mistake, just modified.
pls have a look. @JckXia

@JckXia
Copy link
Member

JckXia commented Feb 17, 2022

@meixg The change looks good! Thanks for working on this one. We currently have some issues with our CI but that should hopefully clear up soon.

@JckXia
Copy link
Member

JckXia commented Feb 17, 2022

@meixg We've made a change to our windows CI that should unblock this PR. Please pull in the latest changes and push again. Thanks!

Copy link
Member

@NickNaso NickNaso left a comment

Choose a reason for hiding this comment

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

LGTM

@meixg
Copy link
Member Author

meixg commented Feb 18, 2022

@JckXia CI passed.

@JckXia JckXia merged commit b7659db into nodejs:main Feb 18, 2022
@JckXia
Copy link
Member

JckXia commented Feb 18, 2022

Landed as b7659db

@mhdawson
Copy link
Member

Thanks for the contribution. And if you are interested in joining our weekly meetings on Friday at 11ET please feel free to do so.

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.

4 participants