Install anchor from this installation guide https://www.anchor-lang.com/docs/installation
write you smart contract in /anchor/programs
to build use command anchor build
for testing you can use local solana validator
to start it type solana-test-validator and go to explorer.solana.com and select the net to Custom RPC url and past ethe localhost url
now we can watch all the transactions of it there
for testing we use anchor build
install it using npm i anchor-bankrun
to run the tests we can use anchor test --skip-local-validator --skip-deploy