Skip to content

Commit e44fc74

Browse files
Fixes and cleanup for delivery of M2 (#29)
* Add tests for ExtrinsicSignatureV3, SignedBlock * Add more end2end tests as examples, fix errors, change e2e testnet to Kusama CC2 * Replace wrong license
1 parent fa2249c commit e44fc74

42 files changed

Lines changed: 546 additions & 427 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

Makefile

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
# Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
# Copyright (C) 2019 Centrifuge GmbH
32
#
4-
# This file is part of Go Substrate RPC Client (GSRPC).
3+
# Copyright 2019 Centrifuge GmbH
54
#
6-
# GSRPC is free software: you can redistribute it and/or modify
7-
# it under the terms of the GNU General Public License as published by
8-
# the Free Software Foundation, either version 3 of the License, or
9-
# (at your option) any later version.
5+
# Licensed under the Apache License, Version 2.0 (the "License");
6+
# you may not use this file except in compliance with the License.
7+
# You may obtain a copy of the License at
108
#
11-
# GSRPC is distributed in the hope that it will be useful,
12-
# but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
# GNU General Public License for more details.
9+
# http://www.apache.org/licenses/LICENSE-2.0
1510
#
16-
# You should have received a copy of the GNU General Public License
17-
# along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
# Unless required by applicable law or agreed to in writing, software
12+
# distributed under the License is distributed on an "AS IS" BASIS,
13+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
# See the License for the specific language governing permissions and
15+
# limitations under the License.
1816

1917
clean: ##clean vendor folder. Should be run before a make install
2018
@echo 'cleaning previous /vendor folder'
@@ -44,8 +42,8 @@ test-dockerized: ## runs all tests in a docker container against the Substrate
4442
@docker-compose build
4543
@docker-compose up --abort-on-container-exit
4644

47-
test-e2e-deployed: export RPC_URL?=wss://poc3-rpc.polkadot.io
48-
test-e2e-deployed: ## runs only end-to-end (e2e) tests against a deployed testnet (defaults to Alexander (wss://poc3-rpc.polkadot.io) if RPC_URL is not set)
45+
test-e2e-deployed: export RPC_URL?=wss://serinus-5.kusama.network
46+
test-e2e-deployed: ## runs only end-to-end (e2e) tests against a deployed testnet (defaults to Kusama CC2 (wss://serinus-5.kusama.network) if RPC_URL is not set)
4947
@docker build . -t gsrpc-test
5048
@docker run --rm -e RPC_URL gsrpc-test go test -v github.com/centrifuge/go-substrate-rpc-client/teste2e
5149

rpc/chain/get_block_test.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package chain
2018

rpc/chain/get_header_test.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package chain
2018

rpc/state/get_child_keys.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package state
2018

rpc/state/get_child_storage.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package state
2018

rpc/state/get_child_storage_hash.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package state
2018

rpc/state/get_child_storage_size.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package state
2018

rpc/state/get_keys.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package state
2018

rpc/state/get_runtime_version_test.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package state
2018

rpc/state/get_storage.go

Lines changed: 10 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,18 @@
11
// Go Substrate RPC Client (GSRPC) provides APIs and types around Polkadot and any Substrate-based chain RPC calls
2-
// Copyright (C) 2019 Centrifuge GmbH
32
//
4-
// This file is part of Go Substrate RPC Client (GSRPC).
3+
// Copyright 2019 Centrifuge GmbH
54
//
6-
// GSRPC is free software: you can redistribute it and/or modify
7-
// it under the terms of the GNU General Public License as published by
8-
// the Free Software Foundation, either version 3 of the License, or
9-
// (at your option) any later version.
5+
// Licensed under the Apache License, Version 2.0 (the "License");
6+
// you may not use this file except in compliance with the License.
7+
// You may obtain a copy of the License at
108
//
11-
// GSRPC is distributed in the hope that it will be useful,
12-
// but WITHOUT ANY WARRANTY; without even the implied warranty of
13-
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14-
// GNU General Public License for more details.
9+
// http://www.apache.org/licenses/LICENSE-2.0
1510
//
16-
// You should have received a copy of the GNU General Public License
17-
// along with this program. If not, see <https://www.gnu.org/licenses/>.
11+
// Unless required by applicable law or agreed to in writing, software
12+
// distributed under the License is distributed on an "AS IS" BASIS,
13+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
// See the License for the specific language governing permissions and
15+
// limitations under the License.
1816

1917
package state
2018

0 commit comments

Comments
 (0)