From 86bd92ba27a56e97ce0be4d1356d031999c250b8 Mon Sep 17 00:00:00 2001 From: Benjamin DeMann Date: Mon, 1 Jul 2024 13:00:58 -0600 Subject: [PATCH] add missing candid files --- .../class_syntax/motoko_examples/calc/src/index.did | 7 +++++++ .../class_syntax/motoko_examples/counter/src/index.did | 5 +++++ .../class_syntax/motoko_examples/echo/src/index.did | 3 +++ .../motoko_examples/hello-world/src/index.did | 3 +++ .../motoko_examples/hello/src/hello/index.did | 3 +++ .../minimal-counter-dapp/src/minimal_dapp/index.did | 5 +++++ .../motoko_examples/persistent-storage/src/index.did | 6 ++++++ .../motoko_examples/phone-book/src/phone_book/index.did | 4 ++++ .../class_syntax/motoko_examples/quicksort/src/index.did | 3 +++ .../motoko_examples/simple-to-do/src/index.did | 7 +++++++ .../superheroes/src/superheroes/index.did | 9 +++++++++ .../motoko_examples/threshold_ecdsa/src/index.did | 4 ++++ .../class_syntax/motoko_examples/whoami/src/index.did | 7 +++++++ 13 files changed, 66 insertions(+) create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/calc/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/counter/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/echo/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello-world/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello/src/hello/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/minimal-counter-dapp/src/minimal_dapp/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/persistent-storage/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/phone-book/src/phone_book/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/quicksort/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/simple-to-do/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/superheroes/src/superheroes/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/threshold_ecdsa/src/index.did create mode 100644 tests/end_to_end/candid_rpc/class_syntax/motoko_examples/whoami/src/index.did diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/calc/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/calc/src/index.did new file mode 100644 index 0000000000..497f4321ba --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/calc/src/index.did @@ -0,0 +1,7 @@ +service: () -> { + add: (int) -> (int); + clearall: () -> (); + div: (int) -> (opt int); + mul: (int) -> (int); + sub: (int) -> (int); +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/counter/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/counter/src/index.did new file mode 100644 index 0000000000..a0b3a1ed59 --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/counter/src/index.did @@ -0,0 +1,5 @@ +service: () -> { + get: () -> (nat) query; + inc: () -> (); + set: (nat) -> (); +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/echo/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/echo/src/index.did new file mode 100644 index 0000000000..99f2ac5fdc --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/echo/src/index.did @@ -0,0 +1,3 @@ +service: () -> { + say: (text) -> (text) query; +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello-world/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello-world/src/index.did new file mode 100644 index 0000000000..458334c84e --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello-world/src/index.did @@ -0,0 +1,3 @@ +service: () -> { + main: () -> () query; +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello/src/hello/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello/src/hello/index.did new file mode 100644 index 0000000000..b0909eff8d --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/hello/src/hello/index.did @@ -0,0 +1,3 @@ +service: () -> { + greet: (text) -> (text) query; +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/minimal-counter-dapp/src/minimal_dapp/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/minimal-counter-dapp/src/minimal_dapp/index.did new file mode 100644 index 0000000000..96bd0bbf84 --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/minimal-counter-dapp/src/minimal_dapp/index.did @@ -0,0 +1,5 @@ +service: () -> { + count: () -> (nat); + getCount: () -> (nat) query; + reset: () -> (nat); +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/persistent-storage/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/persistent-storage/src/index.did new file mode 100644 index 0000000000..e63226e8ed --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/persistent-storage/src/index.did @@ -0,0 +1,6 @@ +service: () -> { + get: () -> (nat) query; + getRedeployed: () -> (bool) query; + increment: () -> (nat); + reset: () -> (nat); +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/phone-book/src/phone_book/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/phone-book/src/phone_book/index.did new file mode 100644 index 0000000000..2cf23ca350 --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/phone-book/src/phone_book/index.did @@ -0,0 +1,4 @@ +service: () -> { + insert: (text, record {desc:text; phone:text}) -> (); + lookup: (text) -> (opt record {desc:text; phone:text}) query; +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/quicksort/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/quicksort/src/index.did new file mode 100644 index 0000000000..0bf0d725ac --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/quicksort/src/index.did @@ -0,0 +1,3 @@ +service: () -> { + sort: (vec int) -> (vec int) query; +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/simple-to-do/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/simple-to-do/src/index.did new file mode 100644 index 0000000000..a6c08c685d --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/simple-to-do/src/index.did @@ -0,0 +1,7 @@ +service: () -> { + addTodo: (text) -> (nat); + clearCompleted: () -> (); + completeTodo: (nat) -> (); + getTodos: () -> (vec record {completed:bool; description:text}) query; + showTodos: () -> (text) query; +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/superheroes/src/superheroes/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/superheroes/src/superheroes/index.did new file mode 100644 index 0000000000..b0ff080de3 --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/superheroes/src/superheroes/index.did @@ -0,0 +1,9 @@ +type rec_0 = record {text; opt rec_0}; +type rec_1 = record {text; opt rec_1}; +type rec_2 = record {text; opt rec_2}; +service: () -> { + create: (record {superpowers:opt rec_0; name:text}) -> (nat32); + deleteHero: (nat32) -> (bool); + read: (nat32) -> (opt record {superpowers:opt rec_1; name:text}) query; + update: (nat32, record {superpowers:opt rec_2; name:text}) -> (bool); +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/threshold_ecdsa/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/threshold_ecdsa/src/index.did new file mode 100644 index 0000000000..74f57782b3 --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/threshold_ecdsa/src/index.did @@ -0,0 +1,4 @@ +service: () -> { + publicKey: () -> (record {publicKey:vec nat8}); + sign: (vec nat8) -> (record {signature:vec nat8}); +} diff --git a/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/whoami/src/index.did b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/whoami/src/index.did new file mode 100644 index 0000000000..29556c8d4c --- /dev/null +++ b/tests/end_to_end/candid_rpc/class_syntax/motoko_examples/whoami/src/index.did @@ -0,0 +1,7 @@ +service: (principal) -> { + argument: () -> (principal) query; + id: () -> (principal); + idQuick: () -> (principal) query; + installer: () -> (principal) query; + whoami: () -> (principal); +}