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

test: add integration tests for Ownable plugin #59

Merged
merged 2 commits into from
Jan 10, 2023

Conversation

mooori
Copy link
Contributor

@mooori mooori commented Jan 10, 2023

Adds integration tests for Ownable and removes the corresponding unit tests. The background and motivation are described in #51, which does the same for Pausable.

@mooori mooori marked this pull request as ready for review January 10, 2023 15:14
@mooori mooori requested a review from birchmd January 10, 2023 15:14
/// it.
///
/// It is possible to use `#[only(self)]` even if the contract does not derive `Ownable`.
#[only(self)]
Copy link

Choose a reason for hiding this comment

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

Is only(self) equivilent to private from near-sdk?

Copy link
Contributor Author

@mooori mooori Jan 10, 2023

Choose a reason for hiding this comment

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

True, they are equivalent. I think we should mention that in the docs and recommend using #[private] rather than #[only(self)], since the latter is provided by near-sdk directly. Would that make sense?

I’ve merged this PR since it’s intended to be a port of unit to integration tests. In a follow-up PR I can handle the self docs, if necessary.

@mooori mooori merged commit 4847173 into Near-One:master Jan 10, 2023
@mooori mooori deleted the ownable-itest branch January 10, 2023 17:54
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.

3 participants