From e81484a47f4b566cce5dabb3a2a8f40f7aef3207 Mon Sep 17 00:00:00 2001 From: Quentin McGaw Date: Wed, 24 Aug 2022 21:28:30 +0000 Subject: [PATCH 1/2] fix(dot/core): `RuntimeInstance` interface `Version` signature --- dot/core/interface.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dot/core/interface.go b/dot/core/interface.go index 0e796360ca..e3add387c1 100644 --- a/dot/core/interface.go +++ b/dot/core/interface.go @@ -29,7 +29,7 @@ type RuntimeInstance interface { Exec(function string, data []byte) ([]byte, error) SetContextStorage(s runtime.Storage) GetCodeHash() common.Hash - Version() (runtime.Version, error) + Version() (version runtime.Version) Metadata() ([]byte, error) BabeConfiguration() (*types.BabeConfiguration, error) GrandpaAuthorities() ([]types.Authority, error) From 29cd5d1d45b336d8f6d2ce3bbcdc0a7798f1b2f9 Mon Sep 17 00:00:00 2001 From: Quentin McGaw Date: Wed, 24 Aug 2022 21:37:38 +0000 Subject: [PATCH 2/2] Update mock --- dot/core/mocks_test.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/dot/core/mocks_test.go b/dot/core/mocks_test.go index cffa3098c3..1dd9e80725 100644 --- a/dot/core/mocks_test.go +++ b/dot/core/mocks_test.go @@ -1164,12 +1164,11 @@ func (mr *MockRuntimeInstanceMockRecorder) Validator() *gomock.Call { } // Version mocks base method. -func (m *MockRuntimeInstance) Version() (runtime.Version, error) { +func (m *MockRuntimeInstance) Version() runtime.Version { m.ctrl.T.Helper() ret := m.ctrl.Call(m, "Version") ret0, _ := ret[0].(runtime.Version) - ret1, _ := ret[1].(error) - return ret0, ret1 + return ret0 } // Version indicates an expected call of Version.