Spaces:
Running on Zero
Running on Zero
Download node_modules/python/test/python.test.js from Bellok/warbler-cda: direct link, hf CLI and curl.
- Browser
- Download file 667 Bytes
-
https://huggingface.co/spaces/Bellok/warbler-cda/resolve/refs%2Fpr%2F3/node_modules/python/test/python.test.js
- Command line
-
hf download hf://spaces/Bellok/warbler-cda@refs/pr/3/node_modules/python/test/python.test.js
-
curl -L -o python.test.js https://huggingface.co/spaces/Bellok/warbler-cda/resolve/refs%2Fpr%2F3/node_modules/python/test/python.test.js
667 Bytes
| var assert = require('assert'); | |
| var python = require('../lib/python').shell; | |
| var runTests = function() { | |
| // Run a couple commands in series | |
| python('print "Hello World!"', function(err, data) { | |
| assert.equal('Hello World!\n', data); | |
| console.log('test 1 ok!'); | |
| python('print "Goodbye, Cruel World!"', function (err, data) { | |
| assert.equal('Goodbye, Cruel World!\n', data); | |
| console.log('test 2 ok!'); | |
| python('quit()'); | |
| }); | |
| }); | |
| // Run one in parallel with the first two | |
| python('print "Asynch"', function (err, data) { | |
| assert.equal('Asynch\n', data); | |
| console.log('test 3 ok!'); | |
| }); | |
| }; | |
| runTests(); | |