workshopper / workshopper-exercise

An exercise runner component for the Workshopper framework
Other
57 stars 35 forks source link

Running executables as solutions fails #29

Open vidarw opened 9 years ago

vidarw commented 9 years ago

Should it be possible to allow the workshopper to execute binaries and/or other scripts than node scripts? Trying to make a language independent course/workshop. Verification of binaries currently this fails in Windows.

C:\Projects\Git\getajob>learnyounode verify helloworld.exe

C:\Projects\Git\getajob\helloworld.exe:1
(function (exports, require, module, __filename, __dirname) { MZ?
                                                                ^
SyntaxError: Unexpected token ILLEGAL
    at Module._compile (module.js:439:25)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Function.Module.runMain (module.js:497:10)
    at startup (node.js:119:16)
    at node.js:902:3

Your submission results compared to the expected:

                 ACTUAL                                 EXPECTED
────────────────────────────────────────────────────────────────────────────────

   ""                                  !=    "HELLO WORLD"
                                       !=    ""

────────────────────────────────────────────────────────────────────────────────

? Submission results did not match expected!

# FAIL

Your solution to HELLO WORLD didn't pass. Try again!

C:\Projects\Git\getajob>
rvagg commented 9 years ago

It's not currently designed to work like that but you should be able to write your own exercises that are verified by whatever means you can dream up. You'll just have to take execute out of the equation and put something in its place.