Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Duniter v2S
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Monitor
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
nodes
rust
Duniter v2S
Merge requests
!241
Fix warnings during benchmarks
Code
Review changes
Check out branch
Download
Patches
Plain diff
Merged
Fix warnings during benchmarks
198-fix-pallet-identity
into
master
Overview
0
Commits
1
Pipelines
2
Changes
1
Merged
Benjamin Gallois
requested to merge
198-fix-pallet-identity
into
master
1 year ago
Overview
0
Commits
1
Pipelines
2
Changes
1
Expand
Closes
#198 (closed)
Closed
#186 (closed)
(see
#186 (comment 41648)
).
Edited
1 year ago
by
Benjamin Gallois
0
0
Merge request reports
Compare
master
master (base)
and
latest version
latest version
c2b82831
1 commit,
1 year ago
1 file
+
2
−
0
Inline
Compare changes
Side-by-side
Inline
Show whitespace changes
Show one file at a time
pallets/identity/src/benchmarking.rs
+
2
−
0
Options
@@ -101,6 +101,7 @@ mod benchmarks {
};
let
name
=
i
.to_le_bytes
();
let
idty_name
=
IdtyName
(
name
.into
());
frame_system
::
Pallet
::
<
T
>
::
inc_sufficients
(
&
owner_key
);
<
Identities
<
T
>>
::
insert
(
idty_index
,
value
);
IdentityChangeSchedule
::
<
T
>
::
append
(
next_scheduled
,
idty_index
);
IdentityIndexOf
::
<
T
>
::
insert
(
owner_key
.clone
(),
idty_index
);
@@ -403,6 +404,7 @@ mod benchmarks {
let
idty_index
:
T
::
IdtyIndex
=
1u32
.into
();
let
new_identity
:
T
::
AccountId
=
account
(
"Bob"
,
2
,
1
);
assert!
(
Identities
::
<
T
>
::
get
(
idty_index
)
.is_some
());
frame_system
::
Pallet
::
<
T
>
::
inc_sufficients
(
&
new_identity
);
Identities
::
<
T
>
::
mutate
(
idty_index
,
|
id
|
{
if
let
Some
(
id
)
=
id
{
id
.old_owner_key
=
Some
((
new_identity
,
BlockNumberFor
::
<
T
>
::
zero
()));
Loading