Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
YottaChain
YTBP
提交
07675d86
Y
YTBP
项目概览
YottaChain
/
YTBP
通知
0
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Y
YTBP
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
07675d86
编写于
4月 13, 2018
作者:
B
Bill Hamilton
浏览文件
操作
浏览文件
下载
差异文件
Merge branch 'master' into eosio_build_centos
Merging master to avoid conflicts
上级
aa4ae921
2cec2b69
变更
21
显示空白变更内容
内联
并排
Showing
21 changed file
with
160 addition
and
47 deletion
+160
-47
contracts/asserter/asserter.abi
contracts/asserter/asserter.abi
+1
-1
contracts/currency/currency.abi
contracts/currency/currency.abi
+1
-1
contracts/dice/dice.abi
contracts/dice/dice.abi
+1
-1
contracts/eosio.bios/eosio.bios.abi
contracts/eosio.bios/eosio.bios.abi
+1
-1
contracts/eosio.msig/eosio.msig.abi
contracts/eosio.msig/eosio.msig.abi
+1
-1
contracts/eosio.system/eosio.system.abi
contracts/eosio.system/eosio.system.abi
+1
-1
contracts/eosio.token/eosio.token.abi
contracts/eosio.token/eosio.token.abi
+1
-1
contracts/exchange/exchange.abi
contracts/exchange/exchange.abi
+1
-1
contracts/identity/identity.abi
contracts/identity/identity.abi
+1
-1
contracts/multi_index_test/multi_index_test.abi
contracts/multi_index_test/multi_index_test.abi
+1
-1
contracts/noop/noop.abi
contracts/noop/noop.abi
+1
-1
contracts/proxy/proxy.abi
contracts/proxy/proxy.abi
+1
-1
contracts/skeleton/skeleton.abi
contracts/skeleton/skeleton.abi
+1
-1
contracts/stltest/stltest.abi
contracts/stltest/stltest.abi
+1
-1
contracts/tic_tac_toe/tic_tac_toe.abi
contracts/tic_tac_toe/tic_tac_toe.abi
+1
-1
libraries/chain/contracts/chain_initializer.cpp
libraries/chain/contracts/chain_initializer.cpp
+2
-2
libraries/chain/include/eosio/chain/authority.hpp
libraries/chain/include/eosio/chain/authority.hpp
+1
-1
libraries/chain/include/eosio/chain/contracts/types.hpp
libraries/chain/include/eosio/chain/contracts/types.hpp
+3
-3
libraries/chain/include/eosio/chain/resource_limits_private.hpp
...ies/chain/include/eosio/chain/resource_limits_private.hpp
+1
-1
tests/chain_tests/auth_tests.cpp
tests/chain_tests/auth_tests.cpp
+113
-0
tests/tests/abi_tests.cpp
tests/tests/abi_tests.cpp
+25
-25
未找到文件。
contracts/asserter/asserter.abi
浏览文件 @
07675d86
...
@@ -31,5 +31,5 @@
...
@@ -31,5 +31,5 @@
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/currency/currency.abi
浏览文件 @
07675d86
...
@@ -83,5 +83,5 @@
...
@@ -83,5 +83,5 @@
"key_types" : ["uint64"]
"key_types" : ["uint64"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/dice/dice.abi
浏览文件 @
07675d86
...
@@ -213,5 +213,5 @@
...
@@ -213,5 +213,5 @@
"type": "account"
"type": "account"
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/eosio.bios/eosio.bios.abi
浏览文件 @
07675d86
...
@@ -76,5 +76,5 @@
...
@@ -76,5 +76,5 @@
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/eosio.msig/eosio.msig.abi
浏览文件 @
07675d86
...
@@ -125,5 +125,5 @@
...
@@ -125,5 +125,5 @@
"key_types" : ["name"]
"key_types" : ["name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/eosio.system/eosio.system.abi
浏览文件 @
07675d86
...
@@ -239,5 +239,5 @@
...
@@ -239,5 +239,5 @@
],
],
"tables": [
"tables": [
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/eosio.token/eosio.token.abi
浏览文件 @
07675d86
...
@@ -72,5 +72,5 @@
...
@@ -72,5 +72,5 @@
"key_types" : ["uint64"]
"key_types" : ["uint64"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/exchange/exchange.abi
浏览文件 @
07675d86
...
@@ -160,5 +160,5 @@
...
@@ -160,5 +160,5 @@
"key_types" : ["uint64"]
"key_types" : ["uint64"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/identity/identity.abi
浏览文件 @
07675d86
...
@@ -112,5 +112,5 @@
...
@@ -112,5 +112,5 @@
"key_types": [ "account_name" ]
"key_types": [ "account_name" ]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/multi_index_test/multi_index_test.abi
浏览文件 @
07675d86
...
@@ -15,5 +15,5 @@
...
@@ -15,5 +15,5 @@
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/noop/noop.abi
浏览文件 @
07675d86
...
@@ -21,5 +21,5 @@
...
@@ -21,5 +21,5 @@
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/proxy/proxy.abi
浏览文件 @
07675d86
...
@@ -35,5 +35,5 @@
...
@@ -35,5 +35,5 @@
"key_types" : ["name"]
"key_types" : ["name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/skeleton/skeleton.abi
浏览文件 @
07675d86
...
@@ -35,5 +35,5 @@
...
@@ -35,5 +35,5 @@
"key_types" : ["name"]
"key_types" : ["name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/stltest/stltest.abi
浏览文件 @
07675d86
...
@@ -41,5 +41,5 @@
...
@@ -41,5 +41,5 @@
"key_types" : ["my_account_name"]
"key_types" : ["my_account_name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
contracts/tic_tac_toe/tic_tac_toe.abi
浏览文件 @
07675d86
...
@@ -76,5 +76,5 @@
...
@@ -76,5 +76,5 @@
"key_types" : ["account_name"]
"key_types" : ["account_name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
libraries/chain/contracts/chain_initializer.cpp
浏览文件 @
07675d86
...
@@ -76,7 +76,7 @@ abi_def chain_initializer::eos_contract_abi(const abi_def& eosio_system_abi)
...
@@ -76,7 +76,7 @@ abi_def chain_initializer::eos_contract_abi(const abi_def& eosio_system_abi)
eos_abi
.
actions
.
push_back
(
action_def
{
name
(
"onblock"
),
"onblock"
,
""
}
);
eos_abi
.
actions
.
push_back
(
action_def
{
name
(
"onblock"
),
"onblock"
,
""
}
);
eos_abi
.
actions
.
push_back
(
action_def
{
name
(
"canceldelay"
),
"canceldelay"
,
""
}
);
eos_abi
.
actions
.
push_back
(
action_def
{
name
(
"canceldelay"
),
"canceldelay"
,
""
}
);
// TODO add any clauses
// TODO add any
ricardian_
clauses
//
//
// ACTION PAYLOADS
// ACTION PAYLOADS
...
@@ -304,7 +304,7 @@ abi_def chain_initializer::eos_contract_abi(const abi_def& eosio_system_abi)
...
@@ -304,7 +304,7 @@ abi_def chain_initializer::eos_contract_abi(const abi_def& eosio_system_abi)
{
"structs"
,
"struct_def[]"
},
{
"structs"
,
"struct_def[]"
},
{
"actions"
,
"action_def[]"
},
{
"actions"
,
"action_def[]"
},
{
"tables"
,
"table_def[]"
},
{
"tables"
,
"table_def[]"
},
{
"clauses"
,
"clause_pair[]"
}
{
"
ricardian_
clauses"
,
"clause_pair[]"
}
}
}
});
});
...
...
libraries/chain/include/eosio/chain/authority.hpp
浏览文件 @
07675d86
...
@@ -118,7 +118,7 @@ inline bool validate( const Authority& auth ) {
...
@@ -118,7 +118,7 @@ inline bool validate( const Authority& auth ) {
total_weight
+=
a
.
weight
;
total_weight
+=
a
.
weight
;
pa
=
&
a
;
pa
=
&
a
;
}
}
return
total_weight
>
0
&&
total_weight
>=
auth
.
threshold
;
return
auth
.
threshold
>
0
&&
total_weight
>=
auth
.
threshold
;
}
}
}
}
// namespace eosio::chain
}
}
// namespace eosio::chain
...
...
libraries/chain/include/eosio/chain/contracts/types.hpp
浏览文件 @
07675d86
...
@@ -102,14 +102,14 @@ struct clause_pair {
...
@@ -102,14 +102,14 @@ struct clause_pair {
struct
abi_def
{
struct
abi_def
{
abi_def
()
=
default
;
abi_def
()
=
default
;
abi_def
(
const
vector
<
type_def
>&
types
,
const
vector
<
struct_def
>&
structs
,
const
vector
<
action_def
>&
actions
,
const
vector
<
table_def
>&
tables
,
const
vector
<
clause_pair
>&
clauses
)
abi_def
(
const
vector
<
type_def
>&
types
,
const
vector
<
struct_def
>&
structs
,
const
vector
<
action_def
>&
actions
,
const
vector
<
table_def
>&
tables
,
const
vector
<
clause_pair
>&
clauses
)
:
types
(
types
),
structs
(
structs
),
actions
(
actions
),
tables
(
tables
),
clauses
(
clauses
)
:
types
(
types
),
structs
(
structs
),
actions
(
actions
),
tables
(
tables
),
ricardian_
clauses
(
clauses
)
{}
{}
vector
<
type_def
>
types
;
vector
<
type_def
>
types
;
vector
<
struct_def
>
structs
;
vector
<
struct_def
>
structs
;
vector
<
action_def
>
actions
;
vector
<
action_def
>
actions
;
vector
<
table_def
>
tables
;
vector
<
table_def
>
tables
;
vector
<
clause_pair
>
clauses
;
vector
<
clause_pair
>
ricardian_
clauses
;
};
};
struct
newaccount
{
struct
newaccount
{
...
@@ -301,7 +301,7 @@ FC_REFLECT( eosio::chain::contracts::struct_def , (name)(b
...
@@ -301,7 +301,7 @@ FC_REFLECT( eosio::chain::contracts::struct_def , (name)(b
FC_REFLECT
(
eosio
::
chain
::
contracts
::
action_def
,
(
name
)(
type
)(
ricardian_contract
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
action_def
,
(
name
)(
type
)(
ricardian_contract
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
clause_pair
,
(
id
)(
body
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
clause_pair
,
(
id
)(
body
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
table_def
,
(
name
)(
index_type
)(
key_names
)(
key_types
)(
type
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
table_def
,
(
name
)(
index_type
)(
key_names
)(
key_types
)(
type
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
abi_def
,
(
types
)(
structs
)(
actions
)(
tables
)(
clauses
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
abi_def
,
(
types
)(
structs
)(
actions
)(
tables
)(
ricardian_
clauses
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
newaccount
,
(
creator
)(
name
)(
owner
)(
active
)(
recovery
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
newaccount
,
(
creator
)(
name
)(
owner
)(
active
)(
recovery
)
)
FC_REFLECT
(
eosio
::
chain
::
contracts
::
setcode
,
(
account
)(
vmtype
)(
vmversion
)(
code
)
)
//abi
FC_REFLECT
(
eosio
::
chain
::
contracts
::
setcode
,
(
account
)(
vmtype
)(
vmversion
)(
code
)
)
//abi
...
...
libraries/chain/include/eosio/chain/resource_limits_private.hpp
浏览文件 @
07675d86
...
@@ -36,7 +36,7 @@ namespace eosio { namespace chain { namespace resource_limits {
...
@@ -36,7 +36,7 @@ namespace eosio { namespace chain { namespace resource_limits {
uint32_t
last_ordinal
;
///< The ordinal of the last period which has contributed to the average
uint32_t
last_ordinal
;
///< The ordinal of the last period which has contributed to the average
uint64_t
value_ex
;
///< The current average pre-multiplied by Precision
uint64_t
value_ex
;
///< The current average pre-multiplied by Precision
uint64_t
consumed
;
///< The
the
last periods average + the current periods contribution so far
uint64_t
consumed
;
///< The last periods average + the current periods contribution so far
/**
/**
* return the average value
* return the average value
...
...
tests/chain_tests/auth_tests.cpp
浏览文件 @
07675d86
...
@@ -2,6 +2,9 @@
...
@@ -2,6 +2,9 @@
#include <eosio/testing/tester.hpp>
#include <eosio/testing/tester.hpp>
#include <eosio/chain/contracts/abi_serializer.hpp>
#include <eosio/chain/contracts/abi_serializer.hpp>
#include <eosio/chain/resource_limits.hpp>
#include <eosio/chain/resource_limits_private.hpp>
#ifdef NON_VALIDATING_TEST
#ifdef NON_VALIDATING_TEST
#define TESTER tester
#define TESTER tester
#else
#else
...
@@ -318,4 +321,114 @@ BOOST_AUTO_TEST_CASE( any_auth ) { try {
...
@@ -318,4 +321,114 @@ BOOST_AUTO_TEST_CASE( any_auth ) { try {
}
FC_LOG_AND_RETHROW
()
}
}
FC_LOG_AND_RETHROW
()
}
BOOST_AUTO_TEST_CASE
(
no_double_billing
)
{
try
{
TESTER
chain
;
chain
.
produce_block
();
account_name
acc1
=
N
(
"bill1"
);
account_name
acc2
=
N
(
"bill2"
);
account_name
acc1a
=
N
(
"bill1a"
);
chain
.
create_account
(
acc1
);
chain
.
create_account
(
acc1a
);
chain
.
produce_block
();
chainbase
::
database
&
db
=
chain
.
control
->
get_mutable_database
();
using
resource_usage_object
=
eosio
::
chain
::
resource_limits
::
resource_usage_object
;
using
by_owner
=
eosio
::
chain
::
resource_limits
::
by_owner
;
auto
create_acc
=
[
&
](
account_name
a
)
{
signed_transaction
trx
;
chain
.
set_transaction_headers
(
trx
);
authority
owner_auth
=
authority
(
chain
.
get_public_key
(
a
,
"owner"
)
);
vector
<
permission_level
>
pls
=
{{
acc1
,
"active"
}};
pls
.
push_back
({
acc1
,
"owner"
});
// same account but different permission names
pls
.
push_back
({
acc1a
,
"owner"
});
trx
.
actions
.
emplace_back
(
pls
,
contracts
::
newaccount
{
.
creator
=
acc1
,
.
name
=
a
,
.
owner
=
owner_auth
,
.
active
=
authority
(
chain
.
get_public_key
(
a
,
"active"
)
),
.
recovery
=
authority
(
chain
.
get_public_key
(
a
,
"recovery"
)
),
});
chain
.
set_transaction_headers
(
trx
);
trx
.
sign
(
chain
.
get_private_key
(
acc1
,
"active"
),
chain_id_type
()
);
trx
.
sign
(
chain
.
get_private_key
(
acc1
,
"owner"
),
chain_id_type
()
);
trx
.
sign
(
chain
.
get_private_key
(
acc1a
,
"owner"
),
chain_id_type
()
);
return
chain
.
push_transaction
(
trx
);
};
create_acc
(
acc2
);
const
auto
&
usage
=
db
.
get
<
resource_usage_object
,
by_owner
>
(
acc1
);
const
auto
&
usage2
=
db
.
get
<
resource_usage_object
,
by_owner
>
(
acc1a
);
BOOST_TEST
(
usage
.
cpu_usage
.
average
()
>
0
);
BOOST_TEST
(
usage
.
net_usage
.
average
()
>
0
);
BOOST_REQUIRE_EQUAL
(
usage
.
cpu_usage
.
average
(),
usage2
.
cpu_usage
.
average
());
BOOST_REQUIRE_EQUAL
(
usage
.
net_usage
.
average
(),
usage2
.
net_usage
.
average
());
chain
.
produce_block
();
}
FC_LOG_AND_RETHROW
()
}
BOOST_AUTO_TEST_CASE
(
stricter_auth
)
{
try
{
TESTER
chain
;
chain
.
produce_block
();
account_name
acc1
=
N
(
"acc1"
);
account_name
acc2
=
N
(
"acc2"
);
account_name
acc3
=
N
(
"acc3"
);
account_name
acc4
=
N
(
"acc4"
);
chain
.
create_account
(
acc1
);
chain
.
produce_block
();
auto
create_acc
=
[
&
](
account_name
a
,
account_name
creator
,
int
threshold
)
{
signed_transaction
trx
;
chain
.
set_transaction_headers
(
trx
);
authority
invalid_auth
=
authority
(
threshold
,
{
key_weight
{
chain
.
get_public_key
(
a
,
"owner"
),
1
}},
{
permission_level_weight
{{
creator
,
config
::
active_name
},
1
}});
vector
<
permission_level
>
pls
;
pls
.
push_back
({
creator
,
"active"
});
trx
.
actions
.
emplace_back
(
pls
,
contracts
::
newaccount
{
.
creator
=
creator
,
.
name
=
a
,
.
owner
=
authority
(
chain
.
get_public_key
(
a
,
"owner"
)
),
.
active
=
invalid_auth
,
//authority( chain.get_public_key( a, "active" ) ),
.
recovery
=
authority
(
chain
.
get_public_key
(
a
,
"recovery"
)
),
});
chain
.
set_transaction_headers
(
trx
);
trx
.
sign
(
chain
.
get_private_key
(
creator
,
"active"
),
chain_id_type
()
);
return
chain
.
push_transaction
(
trx
);
};
try
{
create_acc
(
acc2
,
acc1
,
0
);
BOOST_FAIL
(
"threshold can't be zero"
);
}
catch
(...)
{
}
try
{
create_acc
(
acc4
,
acc1
,
3
);
BOOST_FAIL
(
"threshold can't be more than total weight"
);
}
catch
(...)
{
}
create_acc
(
acc3
,
acc1
,
1
);
}
FC_LOG_AND_RETHROW
()
}
BOOST_AUTO_TEST_SUITE_END
()
BOOST_AUTO_TEST_SUITE_END
()
tests/tests/abi_tests.cpp
浏览文件 @
07675d86
...
@@ -328,7 +328,7 @@ const char* my_abi = R"=====(
...
@@ -328,7 +328,7 @@ const char* my_abi = R"=====(
],
],
"actions": [],
"actions": [],
"tables": [],
"tables": [],
"clauses": [{"id":"clause A","body":"clause body A"},
"
ricardian_
clauses": [{"id":"clause A","body":"clause body A"},
{"id":"clause B","body":"clause body B"}]
{"id":"clause B","body":"clause body B"}]
}
}
)====="
;
)====="
;
...
@@ -358,7 +358,7 @@ BOOST_AUTO_TEST_CASE(uint_types)
...
@@ -358,7 +358,7 @@ BOOST_AUTO_TEST_CASE(uint_types)
}],
}],
"actions": [],
"actions": [],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -654,7 +654,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_all_types, abi_gen_helper)
...
@@ -654,7 +654,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_all_types, abi_gen_helper)
"type" : "test_struct"
"type" : "test_struct"
}],
}],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)=====";
)=====";
BOOST_TEST( generate_abi(all_types, all_types_abi) == true);
BOOST_TEST( generate_abi(all_types, all_types_abi) == true);
...
@@ -895,7 +895,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_all_indexes, abi_gen_helper)
...
@@ -895,7 +895,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_all_indexes, abi_gen_helper)
},
},
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1053,7 +1053,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_full_table_decl, abi_gen_helper)
...
@@ -1053,7 +1053,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_full_table_decl, abi_gen_helper)
"uint64"
"uint64"
]
]
}],
}],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1105,7 +1105,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_str_table_decl, abi_gen_helper)
...
@@ -1105,7 +1105,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_str_table_decl, abi_gen_helper)
"type": "table1"
"type": "table1"
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1203,7 +1203,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_template_base, abi_gen_helper)
...
@@ -1203,7 +1203,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_template_base, abi_gen_helper)
"uint64"
"uint64"
]
]
}],
}],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1255,7 +1255,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_action_and_table, abi_gen_helper)
...
@@ -1255,7 +1255,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_action_and_table, abi_gen_helper)
"uint64"
"uint64"
]
]
}],
}],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1319,7 +1319,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_simple_typedef, abi_gen_helper)
...
@@ -1319,7 +1319,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_simple_typedef, abi_gen_helper)
"ricardian_contract" : ""
"ricardian_contract" : ""
}],
}],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1397,7 +1397,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_field_typedef, abi_gen_helper)
...
@@ -1397,7 +1397,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_field_typedef, abi_gen_helper)
"uint64"
"uint64"
]
]
}],
}],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1465,7 +1465,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_vector_of_POD, abi_gen_helper)
...
@@ -1465,7 +1465,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_vector_of_POD, abi_gen_helper)
"type": "table1"
"type": "table1"
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1549,7 +1549,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_vector_of_structs, abi_gen_helper)
...
@@ -1549,7 +1549,7 @@ BOOST_FIXTURE_TEST_CASE(abigen_vector_of_structs, abi_gen_helper)
"type": "table1"
"type": "table1"
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1640,7 +1640,7 @@ BOOST_FIXTURE_TEST_CASE(abgigen_vector_alias, abi_gen_helper)
...
@@ -1640,7 +1640,7 @@ BOOST_FIXTURE_TEST_CASE(abgigen_vector_alias, abi_gen_helper)
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1700,7 +1700,7 @@ BOOST_FIXTURE_TEST_CASE(abgigen_eosioabi_macro, abi_gen_helper)
...
@@ -1700,7 +1700,7 @@ BOOST_FIXTURE_TEST_CASE(abgigen_eosioabi_macro, abi_gen_helper)
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1773,7 +1773,7 @@ BOOST_FIXTURE_TEST_CASE(abgigen_contract_inheritance, abi_gen_helper)
...
@@ -1773,7 +1773,7 @@ BOOST_FIXTURE_TEST_CASE(abgigen_contract_inheritance, abi_gen_helper)
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -1957,20 +1957,20 @@ BOOST_AUTO_TEST_CASE(general)
...
@@ -1957,20 +1957,20 @@ BOOST_AUTO_TEST_CASE(general)
"structs" : [{"name":"struct1", "base":"base1", "fields": [{"name":"name1", "type": "type1"}, {"name":"name2", "type": "type2"}] }],
"structs" : [{"name":"struct1", "base":"base1", "fields": [{"name":"name1", "type": "type1"}, {"name":"name2", "type": "type2"}] }],
"actions" : [{"name":"action1","type":"type1", "ricardian_contract":""}],
"actions" : [{"name":"action1","type":"type1", "ricardian_contract":""}],
"tables" : [{"name":"table1","index_type":"indextype1","key_names":["keyname1"],"key_types":["typename1"],"type":"type1"}],
"tables" : [{"name":"table1","index_type":"indextype1","key_names":["keyname1"],"key_types":["typename1"],"type":"type1"}],
"clauses": []
"
ricardian_
clauses": []
},
},
"abidef_arr": [{
"abidef_arr": [{
"types" : [{"new_type_name":"new", "type":"old"}],
"types" : [{"new_type_name":"new", "type":"old"}],
"structs" : [{"name":"struct1", "base":"base1", "fields": [{"name":"name1", "type": "type1"}, {"name":"name2", "type": "type2"}] }],
"structs" : [{"name":"struct1", "base":"base1", "fields": [{"name":"name1", "type": "type1"}, {"name":"name2", "type": "type2"}] }],
"actions" : [{"name":"action1","type":"type1", "ricardian_contract":""}],
"actions" : [{"name":"action1","type":"type1", "ricardian_contract":""}],
"tables" : [{"name":"table1","index_type":"indextype1","key_names":["keyname1"],"key_types":["typename1"],"type":"type1"}],
"tables" : [{"name":"table1","index_type":"indextype1","key_names":["keyname1"],"key_types":["typename1"],"type":"type1"}],
"clauses": []
"
ricardian_
clauses": []
},{
},{
"types" : [{"new_type_name":"new", "type":"old"}],
"types" : [{"new_type_name":"new", "type":"old"}],
"structs" : [{"name":"struct1", "base":"base1", "fields": [{"name":"name1", "type": "type1"}, {"name":"name2", "type": "type2"}] }],
"structs" : [{"name":"struct1", "base":"base1", "fields": [{"name":"name1", "type": "type1"}, {"name":"name2", "type": "type2"}] }],
"actions" : [{"name":"action1","type":"type1", "ricardian_contract": ""}],
"actions" : [{"name":"action1","type":"type1", "ricardian_contract": ""}],
"tables" : [{"name":"table1","index_type":"indextype1","key_names":["keyname1"],"key_types":["typename1"],"type":"type1"}],
"tables" : [{"name":"table1","index_type":"indextype1","key_names":["keyname1"],"key_types":["typename1"],"type":"type1"}],
"clauses": []
"
ricardian_
clauses": []
}]
}]
}
}
)====="
;
)====="
;
...
@@ -1995,7 +1995,7 @@ BOOST_AUTO_TEST_CASE(abi_cycle)
...
@@ -1995,7 +1995,7 @@ BOOST_AUTO_TEST_CASE(abi_cycle)
"structs": [],
"structs": [],
"actions": [],
"actions": [],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -2017,7 +2017,7 @@ BOOST_AUTO_TEST_CASE(abi_cycle)
...
@@ -2017,7 +2017,7 @@ BOOST_AUTO_TEST_CASE(abi_cycle)
}],
}],
"actions": [],
"actions": [],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -2437,7 +2437,7 @@ BOOST_AUTO_TEST_CASE(setabi)
...
@@ -2437,7 +2437,7 @@ BOOST_AUTO_TEST_CASE(setabi)
"key_types" : ["name"]
"key_types" : ["name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
}
}
)====="
;
)====="
;
...
@@ -2803,7 +2803,7 @@ BOOST_AUTO_TEST_CASE(packed_transaction)
...
@@ -2803,7 +2803,7 @@ BOOST_AUTO_TEST_CASE(packed_transaction)
}
}
],
],
"tables": [],
"tables": [],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
fc
::
variant
var
;
fc
::
variant
var
;
...
@@ -2879,7 +2879,7 @@ BOOST_AUTO_TEST_CASE(abi_type_repeat)
...
@@ -2879,7 +2879,7 @@ BOOST_AUTO_TEST_CASE(abi_type_repeat)
"key_types" : ["name"]
"key_types" : ["name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -2936,7 +2936,7 @@ BOOST_AUTO_TEST_CASE(abi_struct_repeat)
...
@@ -2936,7 +2936,7 @@ BOOST_AUTO_TEST_CASE(abi_struct_repeat)
"key_types" : ["name"]
"key_types" : ["name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
@@ -2996,7 +2996,7 @@ BOOST_AUTO_TEST_CASE(abi_action_repeat)
...
@@ -2996,7 +2996,7 @@ BOOST_AUTO_TEST_CASE(abi_action_repeat)
"key_types" : ["name"]
"key_types" : ["name"]
}
}
],
],
"clauses": []
"
ricardian_
clauses": []
}
}
)====="
;
)====="
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录