Skip to content
This repository has been archived by the owner on May 30, 2019. It is now read-only.

Code does not pass all tests #8

Open
cakesmith opened this issue Sep 22, 2014 · 3 comments · May be fixed by #9
Open

Code does not pass all tests #8

cakesmith opened this issue Sep 22, 2014 · 3 comments · May be fixed by #9

Comments

@cakesmith
Copy link

The current version as it stands does not pass all tests:

Checking global_declaration.js ...
  FAIL: Mismatched declaration
    Expected: {"type":"Identifier","name":"answer","range":[4,10]}
      Actual: {"type":"Identifier","name":"answer","range":[36,42]}

  FAIL: Mismatched renaming
    Expected: ["var $;  // declaration:answer","","$ = 42;  // cursor:answer reference:answer","","console.log('The answer is', $); // reference:answer",""]
      Actual: ["var answer;  // declaration:answer","","$ = 42;  // cursor:answer reference:answer","","console.log('The answer is', $); // reference:answer",""]

  FAIL: Mismatched renaming
    Expected: ["var $$;  // declaration:answer","","$$ = 42;  // cursor:answer reference:answer","","console.log('The answer is', $$); // reference:answer",""]
      Actual: ["var answer;  // declaration:answer","","$$ = 42;  // cursor:answer reference:answer","","console.log('The answer is', $$); // reference:answer",""]

  FAIL: Mismatched renaming
    Expected: ["var _;  // declaration:answer","","_ = 42;  // cursor:answer reference:answer","","console.log('The answer is', _); // reference:answer",""]
      Actual: ["var answer;  // declaration:answer","","_ = 42;  // cursor:answer reference:answer","","console.log('The answer is', _); // reference:answer",""]

  FAIL: Mismatched renaming
    Expected: ["var $unique;  // declaration:answer","","$unique = 42;  // cursor:answer reference:answer","","console.log('The answer is', $unique); // reference:answer",""]
      Actual: ["var answer;  // declaration:answer","","$unique = 42;  // cursor:answer reference:answer","","console.log('The answer is', $unique); // reference:answer",""]

  FAIL: Mismatched renaming
    Expected: ["var loooooong_name;  // declaration:answer","","loooooong_name = 42;  // cursor:answer reference:answer","","console.log('The answer is', loooooong_name); // reference:answer",""]
      Actual: ["var answer;  // declaration:answer","","loooooong_name = 42;  // cursor:answer reference:answer","","console.log('The answer is', loooooong_name); // reference:answer",""]

Checking global_init.js ...
Checking global_leak.js ...
  FAIL: Mismatched declaration
    Expected: null
      Actual: {"type":"Identifier","name":"answer","range":[0,6]}
@cakesmith cakesmith linked a pull request Sep 22, 2014 that will close this issue
@wolframkriesing
Copy link

I tried to dive in and understand the tests, but that seems to be a bit more effort. Some docs on it or the use of some standard (BDD) tool would be great.

@wolframkriesing
Copy link

looks like test for global_declaration.js is failing because of same/alike issue as described in #7

wolframkriesing pushed a commit to uxebu/esrefactor that referenced this issue Oct 6, 2014
Now that all tests pass ariya#8 should be closed too.
@cakesmith
Copy link
Author

This issue is already fixed in #9

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

Successfully merging a pull request may close this issue.

2 participants