Skip to content

Instantly share code, notes, and snippets.

View amazingandyyy's full-sized avatar
🦄

Andy Chen amazingandyyy

🦄
View GitHub Profile
0x247B201d48765910a77AFbc7D3629c9f0cDF8a93
0xe5a3D7d96B1E401B8B8148648008B9F1CF528309
pragma solidity ^0.4.4;
contract HelloEthSalon {
function HelloEthSalon() {
// constructor
}
}
pragma solidity ^0.4.4;
contract HelloEthSalon {
string message = 'Hello Ethereum Salon!'
function HelloEthSalon() {
// constructor
}
function GetMessage() return (string) {
pragma solidity ^0.4.4;
contract HelloEthSalon {
string message = "Hello Ethereum Salon!";
function HelloEthSalon() {
// constructor
}
function GetMessage() returns (string) {
var HelloEthSalon = artifacts.require("./HelloEthSalon.sol");
contract("HelloEthSalon:GetMessage", function (accounts) {
it("should return a correct string", async function () {
const contract = await HelloEthSalon.deployed();
const result = await contract.GetMessage.call();
assert.isTrue(result === "Hello Ethereum Salon!");
});
});
var Migrations = artifacts.require("./Migrations.sol");
var HelloEthSalon = artifacts.require('./HelloEthSalon.sol');
module.exports = function(deployer) {
deployer.deploy(Migrations);
deployer.deploy(HelloEthSalon);
};
pragma solidity ^0.4.4;
contract HelloEthSalon {
string message = "I know smart contract testing!!";
function HelloEthSalon() {
// constructor
}
function GetMessage() returns (string) {
var HelloEthSalon = artifacts.require("./HelloEthSalon.sol");
contract("HelloEthSalon:GetMessage", function (accounts) {
it("should return a correct string", async function () {
const contract = await HelloEthSalon.deployed();
const result = await contract.GetMessage.call();
assert.isTrue(result === "I know smart contract testing!!");
});
});
0x247B201d48765910a77AFbc7D3629c9f0cDF8a93