Simulator UI
Simulation RPC
Bundle Simulation RPC
Simulation API on Virtual Environments
Dashboard से Simulate करें
Dashboard से transaction को simulate करने के लिए, Virtual Environments पर जाएं और left-hand menu से Simulate पर क्लिक करें। Simulated transactions केवल Virtual Environment dashboard के अंदर दिखाई देते हैं और Public Explorer में दिखाई नहीं देंगे। आप Simulator का उपयोग निम्नलिखित तरीकों से कर सकते हैं:- Edit Source का उपयोग करके अपने bugfix की जाँच करने के लिए smart contracts errors को debug करें।
- transactions को network पर persist किए बिना states का अनुभव प्राप्त करने के लिए contracts को call करें।
- State Overrides का उपयोग करके इच्छित contract states सेट करें, ऐसी परिस्थितियों के तहत execution का मूल्यांकन करने के लिए जो chain पर मौजूद नहीं हैं और नहीं होनी चाहिए।
- testing scenarios को validate करने के लिए proof of concept transactions बनाएं।
RPC के माध्यम से Simulate करें
Virtual Environments पर Transactions को RPC methodstenderly_simulate और tenderly_simulateBundle का उपयोग करके भी simulate किया जा सकता है।
हम Simulation RPC को integrate करने की सिफारिश करते हैं, लेकिन Simulation REST API का उपयोग करना संभव है।
- Sender address:
0xe2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2। - DAI contract address:
0x6b175474e89094c44da98b954eedeac495271d0f - State override arguments:
DAI(0x6b175474e89094c44da98b954eedeac495271d0f).wards[0xe2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2e2] = 1
showLineNumbers