Skip to main content
Glama

MCP Ethers Wallet

updateTestHelper.mjs1.28 kB
import fs from 'fs'; import path from 'path'; import { fileURLToPath } from 'url'; const __filename = fileURLToPath(import.meta.url); const __dirname = path.dirname(__filename); // Path to the testContractHelper.ts file const testHelperPath = path.join(__dirname, '../src/tests/utils/testContractHelper.ts'); async function main() { console.log(`Updating test helper at ${testHelperPath}`); // Read the file let content = fs.readFileSync(testHelperPath, 'utf8'); // Replace the hardcoded address const oldAddress = '0x5FbDB2315678afecb367f032d93F642f64180aa3'; const newAddress = '0x5FbDB2315678afecb367f032d93F642f64180aa3'; // Use the same address to ensure consistency const updatedContent = content.replace( `const tokenAddress = "${oldAddress}"`, `const tokenAddress = "${newAddress}"` ); if (content === updatedContent) { console.log("✅ Address already set correctly in the file."); return; } // Write the updated content back to the file fs.writeFileSync(testHelperPath, updatedContent, 'utf8'); console.log(`✅ Updated token address from ${oldAddress} to ${newAddress}`); } main() .then(() => process.exit(0)) .catch((error) => { console.error("Update failed:", error); process.exit(1); });

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/crazyrabbitLTC/mcp-ethers-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server