fix for when runtime API field name is _ (#1191)

* fix for when runtime API field name is _

* add a test

* formatting

---------

Co-authored-by: Tadeo hepperle <tadeo@do-mix.de>
This commit is contained in:
James Wilson
2023-10-05 15:16:15 +02:00
committed by GitHub
parent e91d0c7b37
commit 919b866c0f
5 changed files with 62 additions and 9 deletions
+8
View File
@@ -12,6 +12,7 @@
//! to automatically regenerate `stderr` files, but don't forget to check that new files make sense.
mod dispatch_errors;
mod runtime_apis;
mod storage;
mod utils;
@@ -34,6 +35,13 @@ fn ui_tests() {
.build(storage::metadata_storage_map_no_keys()),
);
// Check runtime APIs with _ in method names work
t.pass(
m.new_test_case()
.name("runtime_api_underscore_method_name")
.build(runtime_apis::metadata_runtime_api_underscore_method_name()),
);
// Test that the codegen can handle the different types of DispatchError.
t.pass(
m.new_test_case()