Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
duniter-parameters-parser
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Marie
duniter-parameters-parser
Commits
9fba1d10
Commit
9fba1d10
authored
7 years ago
by
Marie
Browse files
Options
Downloads
Patches
Plain Diff
v1 longnames
parent
03457c56
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
main.js
+49
-0
49 additions, 0 deletions
main.js
main.test.js
+9
-0
9 additions, 0 deletions
main.test.js
with
58 additions
and
0 deletions
main.js
+
49
−
0
View file @
9fba1d10
...
@@ -35,6 +35,55 @@ module.exports = function(data=[]){
...
@@ -35,6 +35,55 @@ module.exports = function(data=[]){
const
parameter
=
parametersOrder
[
i
];
const
parameter
=
parametersOrder
[
i
];
resultat
[
parameter
]
=
parseFloat
(
data
[
i
]);
resultat
[
parameter
]
=
parseFloat
(
data
[
i
]);
}
}
resultat
.
doc
=
{
en
:{
c
:
"
The %growth of the UD every [dtReeval] period
"
,
growthSpeed
:
"
The %growth of the UD every [udReevaluationInterval] period
"
,
dt
:
"
Time period between two UD.
"
,
udInterval
:
"
Time period between two UD.
"
,
dtReeval
:
"
Time period between two re-evaluations of the UD.
"
,
udReevaluationInterval
:
"
Time period between two re-evaluations of the UD.
"
,
ud0
:
"
UD(0), i.e. initial Universal Dividend
"
,
ud0Amount
:
"
UD(0), i.e. initial Universal Dividend
"
,
udTime0
:
"
Timestamp of first UD.
"
,
ud0Time
:
"
Timestamp of first UD.
"
,
udReevalTime0
:
"
Timestamp of first reevaluation of the UD.
"
,
udReevaluationFirstTime
:
"
Timestamp of first reevaluation of the UD.
"
,
sigPeriod
:
"
Minimum delay between 2 certifications of a same issuer, in seconds. Must be positive or zero.
"
,
certifMinInterval
:
"
Minimum delay between 2 certifications of a same issuer, in seconds. Must be positive or zero.
"
,
msPeriod
:
"
Minimum delay between 2 memberships of a same issuer, in seconds. Must be positive or zero.
"
,
membershipAttemptMinInterval
:
"
Minimum delay between 2 memberships of a same issuer, in seconds. Must be positive or zero.
"
,
sigStock
:
"
Maximum quantity of active certifications made by member.
"
,
maxActiveCertif
:
"
Maximum quantity of active certifications made by member.
"
,
sigWindow
:
"
Maximum delay a certification can wait before being expired for non-writing.
"
,
pendingCertifLifetime
:
"
Maximum delay a certification can wait before being expired for non-writing.
"
,
sigValidity
:
"
Maximum age of an active signature (in seconds)
"
,
certifLifetime
:
"
Maximum age of an active signature (in seconds)
"
,
sigQty
:
"
Minimum quantity of signatures to be part of the WoT
"
,
membershipRequirements_minCertifQty
:
"
Minimum quantity of signatures to be part of the WoT
"
,
idtyWindow
:
"
Maximum delay an identity can wait before being expired for non-writing.
"
,
pendingIdentityLifetime
:
"
Maximum delay an identity can wait before being expired for non-writing.
"
,
msWindow
:
"
Maximum delay a membership can wait before being expired for non-writing.
"
,
pendingMembershipLifetime
:
"
Maximum delay a membership can wait before being expired for non-writing.
"
,
xpercent
:
"
Minimum percent of sentries to reach to match the distance rule
"
,
membershipRequirements_reachableFromMinPercentSentry
:
"
Minimum percent of sentries to reach to match the distance rule
"
,
msValidity
:
"
Maximum age of an active membership (in seconds)
"
,
membershipLifetime
:
"
Maximum age of an active membership (in seconds)
"
,
stepMax
:
"
Maximum distance between each WoT member and a newcomer
"
,
membershipRequirements_maxStepFromSentry
:
"
Maximum distance between each WoT member and a newcomer
"
,
medianTimeBlocks
:
"
Number of blocks used for calculating median time.
"
,
blocksRangeToComputeMedianTime
:
"
Number of blocks used for calculating median time.
"
,
avgGenTime
:
"
The average time for writing 1 block (wished time)
"
,
blockComputationAvgTime
:
"
The average time for writing 1 block (wished time)
"
,
dtDiffEval
:
"
The number of blocks required to evaluate again PoWMin value
"
,
blocksRangeForBlockComputationDifficultyCalculation
:
"
The number of blocks required to evaluate again PoWMin value
"
,
percentRot
:
"
The percent of previous issuers to reach for personalized difficulty
"
,
blockComputationCustomDifficultyMagic
:
"
The percent of previous issuers to reach for personalized difficulty
"
,
txWindow
:
"
= 3600 * 24 * 7. Maximum delay a transaction can wait before being expired for non-writing.
"
,
pendingTransactionLifetime
:
"
= 3600 * 24 * 7. Maximum delay a transaction can wait before being expired for non-writing.
"
},
fr
:{}
}
//TODO: doc.fr et doc.en
//TODO: doc.fr et doc.en
//TODO: humanReadable
//TODO: humanReadable
//TODO: longName.fr .en
//TODO: longName.fr .en
...
...
This diff is collapsed.
Click to expand it.
main.test.js
+
9
−
0
View file @
9fba1d10
...
@@ -33,3 +33,12 @@ describe('app returns Ǧ1 parameters by default', () => {
...
@@ -33,3 +33,12 @@ describe('app returns Ǧ1 parameters by default', () => {
});
});
}
}
});
});
describe
(
'
app expose doc
'
,
()
=>
{
it
(
`doc.en.c has value`
,
()
=>
{
expect
(
app
().
doc
.
en
.
c
).
toBeDefined
();
//("The %growth of the UD every [dt] period");
});
it
(
`doc.en also exist with longName`
,
()
=>
{
expect
(
app
().
doc
.
en
.
growthSpeed
).
toBeDefined
();
//("The %growth of the UD every [dt] period");
});
});
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment