ericblade / quagga2

An advanced barcode-scanner written in Javascript and TypeScript - Continuation from https://github.com/serratus/quaggajs
MIT License
758 stars 85 forks source link

Add more test fixtures for Code-32 #214

Closed ericblade closed 4 years ago

ericblade commented 4 years ago

Now that we have Code 32, thank you, @stefanocali , it would be great if you could grab some more real life images and put them into the tests. Most of the other readers have around 10 images.

stefanocali commented 4 years ago

I tried the files and they work, but I noticed that in the image that in the images that begin with "A0", that is, from image 6 to 10. The conversion works, but it does not add me the character "0". Let me explain better, the result should be an example:

image-6

Exact result: A012745182 Result obtained: A12745182

The cause probably depends on the for loop. I'm seeing if it's a string length issue.

stefanocali commented 4 years ago

Nothing, mistake found. I have corrected the file

ericblade commented 4 years ago

Reasons I love tests :-D

Pull request whenever you're ready :) Thanks!

stefanocali commented 4 years ago

I have already updated the files in the old pull. Here: https://github.com/stefanocali/quagga2

ericblade commented 4 years ago

ok, i've merged that, and a couple of other commits, so you should, assuming you have my repo as a remote called upstream, and yours as a remote called origin, git pull --rebase upstream/master to put your most recent changes on top, then git push --force origin master to put that correct in your master, and then pull req again

if you don't have me as upstream, then git remote add upstream https://github.com/ericblade/quagga2.git first.

you might have some merge conflicts to edit, as i ran eslint --fix on some of the code since accepting that pull