sp-api: Remove requirement on Get*BlockType (#14299)

Remove the requirement on `GetNodeBlockType` and `GetRuntimeBlockType`. Actually this wasn't already
used anymore and only referenced in tests.
This commit is contained in:
Bastian Köcher
2023-06-04 09:55:53 +01:00
committed by GitHub
parent 51c87d8525
commit e7a27a31b1
27 changed files with 84 additions and 176 deletions
@@ -18,16 +18,13 @@
use sp_api::{
decl_runtime_apis, impl_runtime_apis, mock_impl_runtime_apis, ApiError, ApiExt, RuntimeApiInfo,
};
use sp_runtime::traits::{Block as BlockT, GetNodeBlockType};
use sp_runtime::traits::Block as BlockT;
use substrate_test_runtime_client::runtime::{Block, Hash};
/// The declaration of the `Runtime` type and the implementation of the `GetNodeBlockType`
/// trait are done by the `construct_runtime!` macro in a real runtime.
/// The declaration of the `Runtime` type is done by the `construct_runtime!` macro in a real
/// runtime.
pub struct Runtime {}
impl GetNodeBlockType for Runtime {
type NodeBlock = Block;
}
decl_runtime_apis! {
pub trait Api {