TTLabs / EvaporateJS

Javascript library for browser to S3 multipart resumable uploads
1.82k stars 207 forks source link

Fix misspelling of progress. #422

Open acinader opened 5 years ago

bikeath1337 commented 5 years ago

Let's start with creating a correctly-spelled alias for the method and include a test that verified it. As it stands, this change can easily break existing usage.

acinader commented 5 years ago

hi @bikeath1337

I added a deprecation warning and kept the current function.

found another typo in the evaporate.spec.js file.

I haven't figured out how to test the FileUpload change yet.

I have never used ava and I can't figure out how to

a) run a single test b) halt in a either chrome debugger or vscode debugger so I can figure out what is going on :).

jakubzitny commented 5 years ago

a) test.only b) vscode debugger should respect the breakpoints (or debugger) as you'd expect if configured properly, adding following to configurations in launch.json should do just fine

{
  "type": "node",
  "request": "attach",
  "name": "node debug"
},
acinader commented 5 years ago

@jakubzitny well test.only works like a charm, but debugging not yet.

In your suggestion above, how do you start the debugger? If I just npm test, then the node runtime isn't in debug mode for vscode to attach to? If I try:

./node_modules/.bin/babel-node --inspect-brk node_modules/ava/profile.js test/evaporate.spec.js

I get this error in the debugger:

Error: Cannot find module './test/helpers/browser-env.js'

which is the same error I get when I try a vscode config like:

        {
            "type": "node",
            "request": "launch",
            "name": "Run AVA test",
            "program": "${workspaceFolder}/node_modules/ava/profile.js",
            "args": [
              "test/evaporate.spec.js"
            ],
            "skipFiles": [
                "<node_internals>/**/*.js"
            ],
        }

which I got from: https://github.com/avajs/ava/blob/master/docs/recipes/debugging-with-vscode.md

I understand what browser-env is trying to do, i'm just not sure how to invoke at the command line rather than using npm and have browser-env do its thing....

jakubzitny commented 5 years ago

Any plans on finishing this @acinader ?

acinader commented 5 years ago

I was unable to get the tests working back when I tried so I have given up.

On Apr 17, 2019, at 4:18 AM, Jakub Žitný notifications@github.com wrote:

Any plans on finishing this @acinader ?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.