Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fuzz testing setup #6

Merged
merged 19 commits into from
Sep 28, 2019
Merged

Add fuzz testing setup #6

merged 19 commits into from
Sep 28, 2019

Conversation

papandreou
Copy link
Contributor

This is how I found out what to fix in #5

This PR will be marked as failing, but when combined with the fixes in #5 it will succeed.

@lovell
Copy link
Collaborator

lovell commented Sep 25, 2019

@papandreou Thank you for these tests. I tried running them locally after merging #5 but see a few failures that all look a bit like:

  expected Buffer([0x45, 0x78, 0x69, 0x66, 0x00, 0x00, 0x4D, 0x4D, 0x00, 0x2A, 0x00, 0x00, 0x00, 0x08, 0x00, 0x0B /* 8142 more */ ]) to either parse or throw documented error
    Threw unexpected error: TypeError [ERR_INVALID_ARG_TYPE]: The "offset" argument must be of type number. Received type string
        at validateNumber (internal/validators.js:130:11)

I realise this PR was opened a while ago, so no worries if you're unable to do so now, but if you do have the time please can you see if there's anything obvious that can be updated/fixed so we can merge this useful feature.

* master:
  Exit early in case of unknown or bogus tag type (devongovett#9)
  Add range checks to guard against invalid input (devongovett#5)
  1.0.2
  Fix issue devongovett#7
  1.0.1
  Use UTC time for date objects
@papandreou
Copy link
Contributor Author

@lovell, got it back into shape now and found another bug (#14) 🤗

Copy link
Collaborator

@lovell lovell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for updating this, there's one comment inline but otherwise this is good to go.

index.js Outdated Show resolved Hide resolved
* master:
  Don't try to use a non-integer as an offset into the buffer (devongovett#14)
@lovell lovell merged commit 855fb5a into devongovett:master Sep 28, 2019
@lovell
Copy link
Collaborator

lovell commented Sep 28, 2019

Brilliant, thank you Andreas.

@lovell lovell mentioned this pull request Sep 29, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants