Change parameter order

Move parameters belonging to the bid together.
This commit is contained in:
Mark Spanbroek 2021-11-01 16:23:37 +01:00
parent 650f5d1f1a
commit eefa23ff02
5 changed files with 24 additions and 24 deletions

View File

@ -36,12 +36,12 @@ contract Contracts {
uint duration, uint duration,
uint size, uint size,
bytes32 contentHash, bytes32 contentHash,
uint price,
uint proofPeriod, uint proofPeriod,
uint proofTimeout, uint proofTimeout,
bytes32 nonce, bytes32 nonce,
uint bidExpiry, uint price,
address host, address host,
uint bidExpiry,
bytes memory requestSignature, bytes memory requestSignature,
bytes memory bidSignature bytes memory bidSignature
) )

View File

@ -10,12 +10,12 @@ contract StorageContracts is Contracts, Proofs {
uint _duration, uint _duration,
uint _size, uint _size,
bytes32 _contentHash, bytes32 _contentHash,
uint _price,
uint _proofPeriod, uint _proofPeriod,
uint _proofTimeout, uint _proofTimeout,
bytes32 _nonce, bytes32 _nonce,
uint _bidExpiry, uint _price,
address _host, address _host,
uint _bidExpiry,
bytes memory requestSignature, bytes memory requestSignature,
bytes memory bidSignature bytes memory bidSignature
) )
@ -25,12 +25,12 @@ contract StorageContracts is Contracts, Proofs {
_duration, _duration,
_size, _size,
_contentHash, _contentHash,
_price,
_proofPeriod, _proofPeriod,
_proofTimeout, _proofTimeout,
_nonce, _nonce,
_bidExpiry, _price,
_host, _host,
_bidExpiry,
requestSignature, requestSignature,
bidSignature bidSignature
); );

View File

@ -9,12 +9,12 @@ contract TestContracts is Contracts {
uint _duration, uint _duration,
uint _size, uint _size,
bytes32 _contentHash, bytes32 _contentHash,
uint _price,
uint _proofPeriod, uint _proofPeriod,
uint _proofTimeout, uint _proofTimeout,
bytes32 _nonce, bytes32 _nonce,
uint _bidExpiry, uint _price,
address _host, address _host,
uint _bidExpiry,
bytes memory requestSignature, bytes memory requestSignature,
bytes memory bidSignature bytes memory bidSignature
) )
@ -24,12 +24,12 @@ contract TestContracts is Contracts {
_duration, _duration,
_size, _size,
_contentHash, _contentHash,
_price,
_proofPeriod, _proofPeriod,
_proofTimeout, _proofTimeout,
_nonce, _nonce,
_bidExpiry, _price,
_host, _host,
_bidExpiry,
requestSignature, requestSignature,
bidSignature); bidSignature);
} }

View File

@ -40,12 +40,12 @@ describe("Storage Contracts", function () {
duration, duration,
size, size,
contentHash, contentHash,
price,
proofPeriod, proofPeriod,
proofTimeout, proofTimeout,
nonce, nonce,
bidExpiry, price,
await host.getAddress(), await host.getAddress(),
bidExpiry,
await sign(client, requestHash), await sign(client, requestHash),
await sign(host, bidHash) await sign(host, bidHash)
) )
@ -61,12 +61,12 @@ describe("Storage Contracts", function () {
duration, duration,
size, size,
contentHash, contentHash,
price,
proofPeriod, proofPeriod,
proofTimeout, proofTimeout,
nonce, nonce,
bidExpiry, price,
await host.getAddress(), await host.getAddress(),
bidExpiry,
await sign(client, requestHash), await sign(client, requestHash),
await sign(host, bidHash) await sign(host, bidHash)
) )
@ -74,12 +74,12 @@ describe("Storage Contracts", function () {
duration, duration,
size, size,
contentHash, contentHash,
price,
proofPeriod, proofPeriod,
proofTimeout, proofTimeout,
nonce, nonce,
bidExpiry, price,
await host.getAddress(), await host.getAddress(),
bidExpiry,
await sign(client, requestHash), await sign(client, requestHash),
await sign(host, bidHash) await sign(host, bidHash)
)).to.be.revertedWith("A contract with this id already exists") )).to.be.revertedWith("A contract with this id already exists")
@ -99,12 +99,12 @@ describe("Storage Contracts", function () {
duration, duration,
size, size,
contentHash, contentHash,
price,
proofPeriod, proofPeriod,
proofTimeout, proofTimeout,
nonce, nonce,
bidExpiry, price,
await host.getAddress(), await host.getAddress(),
bidExpiry,
invalidSignature, invalidSignature,
await sign(host, bidHash) await sign(host, bidHash)
)).to.be.revertedWith("Invalid signature") )).to.be.revertedWith("Invalid signature")
@ -117,12 +117,12 @@ describe("Storage Contracts", function () {
duration, duration,
size, size,
contentHash, contentHash,
price,
proofPeriod, proofPeriod,
proofTimeout, proofTimeout,
nonce, nonce,
bidExpiry, price,
await host.getAddress(), await host.getAddress(),
bidExpiry,
await sign(client, requestHash), await sign(client, requestHash),
invalidSignature invalidSignature
)).to.be.revertedWith("Invalid signature") )).to.be.revertedWith("Invalid signature")
@ -135,12 +135,12 @@ describe("Storage Contracts", function () {
duration, duration,
size, size,
contentHash, contentHash,
price,
proofPeriod, proofPeriod,
proofTimeout, proofTimeout,
nonce, nonce,
expired, price,
await host.getAddress(), await host.getAddress(),
expired,
await sign(client, requestHash), await sign(client, requestHash),
await sign(host, bidHash), await sign(host, bidHash),
)).to.be.revertedWith("Bid expired") )).to.be.revertedWith("Bid expired")

View File

@ -42,12 +42,12 @@ describe("Storage Contracts", function () {
duration, duration,
size, size,
contentHash, contentHash,
price,
proofPeriod, proofPeriod,
proofTimeout, proofTimeout,
nonce, nonce,
bidExpiry, price,
await host.getAddress(), await host.getAddress(),
bidExpiry,
await sign(client, requestHash), await sign(client, requestHash),
await sign(host, bidHash) await sign(host, bidHash)
) )