Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

before, beforeEach doesn't work #2

Open
CamTosh opened this issue Nov 3, 2017 · 1 comment
Open

before, beforeEach doesn't work #2

CamTosh opened this issue Nov 3, 2017 · 1 comment

Comments

@CamTosh
Copy link

CamTosh commented Nov 3, 2017

Hi !

Before and beforeEach method doesn't work. Can you fix that ? :)

I try this code :

    function before_test_method1() {
        anotherValue = 8;
    }

    function test_method1() {
        assertEq(someValue, uint(3), "some value should be 3");
        assertEq(anotherValue, uint(8), "another value should be 8");
    }

Output :

Error: [wafr] ERROR: while compiling contracts in path wafr/src: wafr/Test.sol:4:3: Warning: No visibility specified. Defaulting to "public".
  function () payable {}
  ^--------------------^

    at throwError (wafr/node_modules/wafr/src/utils/index.js:11:9)
    at output.errors.forEach (wafr/node_modules/wafr/src/index.js:573:9)
    at Array.forEach (<anonymous>)
    at getInputSources (wafr/node_modules/wafr/src/index.js:572:21)
    at dir.readFiles (wafr/node_modules/wafr/src/utils/index.js:232:13)
    at wafr/node_modules/node-dir/lib/readfiles.js:110:34
    at FSReqWrap.readFileAfterClose [as oncomplete] (fs.js:528:3)

Version

  • Mac OS
  • Node v9.0.0
  • Solc : Version: 0.4.18+commit.9cf6e910.Darwin.appleclang
@SilentCicero
Copy link
Owner

SilentCicero commented Nov 3, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants