iotaledger / wasp

Node for IOTA Smart Contracts
Apache License 2.0
289 stars 147 forks source link

Docs/move get balance.sol from wiki #3448

Closed salaheldinsoliman closed 1 month ago

salaheldinsoliman commented 1 month ago

Description of change

This is the first PR addressing moving Wiki contracts to the wasp repo. A GetBalance.sol contract was added, alongside a solo test for it.

Links to any relevant issues

fixes issue: https://github.com/iotaledger/iota-wiki/issues/1611

How the change has been tested

A Solo test.

Change checklist

Tick the boxes that are relevant to your changes, and delete any items that are not.

Dr-Electron commented 1 month ago

Just a small comment. Let's move this into its own subfolder. Something like how-tos. This will make it more clear that the team has to be careful when changing this docs as we import them in the wiki. Maybe even add a note about that somewhere in the files? Because we might import subparts of the code and if someone changes a line or two it will break what we show in the wiki

salaheldinsoliman commented 1 month ago

Just a small comment. Let's move this into its own subfolder. Something like how-tos. This will make it more clear that the team has to be careful when changing this docs as we import them in the wiki. Maybe even add a note about that somewhere in the files? Because we might import subparts of the code and if someone changes a line or two it will break what we show in the wiki

@Dr-Electron I initially wanted to implement it in /wasp/documentation/tutorial-examples/test, but we would need to modify the CI to build solidity contracts in that dir too. Do you mean a subfolder under the same evmtest dir?

Dr-Electron commented 1 month ago

Just a small comment. Let's move this into its own subfolder. Something like how-tos. This will make it more clear that the team has to be careful when changing this docs as we import them in the wiki. Maybe even add a note about that somewhere in the files? Because we might import subparts of the code and if someone changes a line or two it will break what we show in the wiki

@Dr-Electron I initially wanted to implement it in /wasp/documentation/tutorial-examples/test, but we would need to modify the CI to build solidity contracts in that dir too. Do you mean a subfolder under the same evmtest dir?

Yeah lets keep it in evmtest so the CI need no or just minor changes. But have a subfolder there. Maybe some day we can revisit that whole importing logic 👍

jorgemmsilva commented 1 month ago

you can absolutely create a new directory like /wasp/documentation/tutorial-examples/test. just add another line here: https://github.com/iotaledger/wasp/blob/develop/Makefile#L39 after that make compile-solidity should compile stuff inside the new dir

salaheldinsoliman commented 1 month ago

@jorgemmsilva @Dr-Electron How about a subdir wiki-how-tos under evmtest, to keep all Solidity there? and also since it is not really a tutorial

jorgemmsilva commented 1 month ago

@salaheldinsoliman sounds good to me :+1:

Dr-Electron commented 1 month ago

I personally would just call it how_tos so it is the same as in the SDK. But yeah that sounds good. Go for it