Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

frame-support-test: migrate tests from decl_* macros to the new pallet macros #12445

Merged
merged 21 commits into from
May 9, 2023
Merged

frame-support-test: migrate tests from decl_* macros to the new pallet macros #12445

merged 21 commits into from
May 9, 2023

Conversation

koushiro
Copy link
Contributor

@koushiro koushiro commented Oct 7, 2022

What does it do?

This PR is a part of #12248 and it need #12401 to be merged firstly

In this PR, I migrate the tests of frame/support/test from old decl_* macros to the new pallet attribute macros, and remove some useless tests.

After this, I will remove the decl_* macros and do some other trivial things.

@koushiro koushiro changed the title Remove decl macros part2 frame-support-test: migrate tests from decl_* macros to the new pallet macros Oct 7, 2022
@koushiro
Copy link
Contributor Author

koushiro commented Oct 8, 2022

Maybe I should use frame-system directly as base config to replace frame-support-test pallet and system module? What do you think?

By now, I removed the system module and used frame-system-test pallet as base config.

Copy link
Contributor

@kianenigma kianenigma left a comment

Choose a reason for hiding this comment

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

Didn't look too closely, but LGTM.

@koushiro
Copy link
Contributor Author

@kianenigma I think #12401 could be reviewed and merged firstly?

@stale
Copy link

stale bot commented Nov 17, 2022

Hey, is anyone still working on this? Due to the inactivity this issue has been automatically marked as stale. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the A5-stale Pull request did not receive any updates in a long time. No review needed at this stage. Close it. label Nov 17, 2022
@stale stale bot removed the A5-stale Pull request did not receive any updates in a long time. No review needed at this stage. Close it. label Nov 17, 2022
@koushiro koushiro closed this Dec 5, 2022
@kianenigma kianenigma added the A0-please_review Pull request needs code review. label Mar 16, 2023
@kianenigma kianenigma reopened this Mar 16, 2023
@ggwpez ggwpez self-assigned this Apr 12, 2023
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
/// sufficient balance to cover the minimum stake for the role.
/// Bonding only occurs after successful entry into a role.
#[pallet::storage]
#[pallet::getter(fn role_entry_requests)]
Copy link
Member

Choose a reason for hiding this comment

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

I will keep the getters in the tests as we should remove them here last IMHO as to not accidentally break them.

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@ggwpez ggwpez added B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit labels Apr 28, 2023
@ggwpez
Copy link
Member

ggwpez commented Apr 29, 2023

bot rebase

@paritytech-processbot
Copy link

Rebased

@ggwpez
Copy link
Member

ggwpez commented May 2, 2023

bot rebase

@paritytech-processbot
Copy link

Rebased

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
@ggwpez ggwpez requested a review from a team May 8, 2023 12:25
@ggwpez
Copy link
Member

ggwpez commented May 9, 2023

bot merge

@paritytech-processbot paritytech-processbot bot merged commit f0c14f3 into paritytech:master May 9, 2023
@koushiro koushiro deleted the remove-decl-macros-part2 branch May 9, 2023 09:24
@ggwpez
Copy link
Member

ggwpez commented May 9, 2023

/tip large

(combined tip together for #12401, therefore large)

@substrate-tip-bot
Copy link

@ggwpez Contributor did not properly post their account address.

Make sure the pull request description has: "{network} address: {address}".

@sam0x17
Copy link
Contributor

sam0x17 commented May 9, 2023

showerthought: would be cool if they could just specify it in their github bio 🤔

nathanwhit pushed a commit to nathanwhit/substrate that referenced this pull request Jul 19, 2023
…llet` macros (paritytech#12445)

* frame-support: migrate some tests from decl macros to new pallet attribute macros

* Remove useless type alias

* Remove useless type alias

* frame-support-test: migrate old decl_macros to new pallet attribute macros

* fmt

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix tests

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix features

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove deprecated stuff

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update UI tests

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix UI test

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Fix test

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Update UI tests

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Cleanup

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
Co-authored-by: parity-processbot <>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D3-trivial 🧸 PR contains trivial changes in a runtime directory that do not require an audit
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

4 participants