swift-extras / swift-extras-json

JSON encoding and decoding without the use of Foundation in pure Swift.
Apache License 2.0
348 stars 15 forks source link

Only increment Unkeyed Decoder Index if Decoding Succeeds #61

Closed calebkleveter closed 4 years ago

calebkleveter commented 4 years ago

This is how the Foundation JSONDecoder behaves and we want to match that for consistency sake.

codecov[bot] commented 4 years ago

Codecov Report

Merging #61 into master will decrease coverage by 5.85%. The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #61      +/-   ##
==========================================
- Coverage   90.73%   84.88%   -5.86%     
==========================================
  Files          40       13      -27     
  Lines        3378     1217    -2161     
==========================================
- Hits         3065     1033    -2032     
+ Misses        313      184     -129     
Impacted Files Coverage Δ
...ftJSON/Decoding/JSONUnkeyedDecodingContainer.swift 94.50% <100.00%> (-0.74%) :arrow_down:
...s/PureSwiftJSONTests/Parsing/JSONParserTests.swift
...ts/PureSwiftJSONTests/Parsing/JSONValueTests.swift
...64-unknown-linux/debug/testlist.derived/main.swift
Tests/PureSwiftJSONTests/ArrayKeyTests.swift
...ux/debug/testlist.derived/PureSwiftJSONTests.swift
...kageTestsTestlist.derived/PureSwiftJSONTests.swift
...PureSwiftJSONTests/Parsing/StringParserTests.swift
...arningTests/FoundationJSONSerializationTests.swift
...sts/Decoding/JSONKeyedDecodingContainerTests.swift
... and 18 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 5dc8ec1...064c1f6. Read the comment docs.