csvlint 1.0.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. checksums.yaml +4 -4
  2. data/.github/dependabot.yml +4 -0
  3. data/.github/workflows/push.yml +14 -2
  4. data/.pre-commit-hooks.yaml +5 -0
  5. data/.ruby-version +1 -1
  6. data/.standard_todo.yml +43 -0
  7. data/CHANGELOG.md +84 -32
  8. data/Dockerfile +16 -0
  9. data/Gemfile +2 -2
  10. data/README.md +30 -9
  11. data/Rakefile +7 -7
  12. data/csvlint.gemspec +14 -16
  13. data/docker_notes_for_windows.txt +20 -0
  14. data/features/step_definitions/cli_steps.rb +11 -11
  15. data/features/step_definitions/information_steps.rb +4 -4
  16. data/features/step_definitions/parse_csv_steps.rb +11 -11
  17. data/features/step_definitions/schema_validation_steps.rb +10 -10
  18. data/features/step_definitions/sources_steps.rb +1 -1
  19. data/features/step_definitions/validation_errors_steps.rb +19 -19
  20. data/features/step_definitions/validation_info_steps.rb +9 -9
  21. data/features/step_definitions/validation_warnings_steps.rb +11 -11
  22. data/features/support/aruba.rb +6 -6
  23. data/features/support/earl_formatter.rb +39 -39
  24. data/features/support/env.rb +10 -11
  25. data/features/support/load_tests.rb +107 -103
  26. data/features/support/webmock.rb +2 -2
  27. data/lib/csvlint/cli.rb +133 -130
  28. data/lib/csvlint/csvw/column.rb +279 -280
  29. data/lib/csvlint/csvw/date_format.rb +90 -92
  30. data/lib/csvlint/csvw/metadata_error.rb +1 -3
  31. data/lib/csvlint/csvw/number_format.rb +40 -32
  32. data/lib/csvlint/csvw/property_checker.rb +714 -717
  33. data/lib/csvlint/csvw/table.rb +49 -52
  34. data/lib/csvlint/csvw/table_group.rb +24 -23
  35. data/lib/csvlint/error_collector.rb +2 -0
  36. data/lib/csvlint/error_message.rb +0 -1
  37. data/lib/csvlint/field.rb +153 -141
  38. data/lib/csvlint/schema.rb +34 -42
  39. data/lib/csvlint/validate.rb +161 -143
  40. data/lib/csvlint/version.rb +1 -1
  41. data/lib/csvlint.rb +22 -23
  42. data/spec/csvw/column_spec.rb +15 -16
  43. data/spec/csvw/date_format_spec.rb +5 -7
  44. data/spec/csvw/number_format_spec.rb +2 -4
  45. data/spec/csvw/table_group_spec.rb +103 -105
  46. data/spec/csvw/table_spec.rb +71 -73
  47. data/spec/field_spec.rb +116 -121
  48. data/spec/schema_spec.rb +129 -139
  49. data/spec/spec_helper.rb +6 -6
  50. data/spec/validator_spec.rb +167 -190
  51. metadata +23 -55
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: csvlint
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - pezholio
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-07-13 00:00:00.000000000 Z
11
+ date: 2023-02-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rainbow
@@ -388,6 +388,20 @@ dependencies:
388
388
  - - ">="
389
389
  - !ruby/object:Gem::Version
390
390
  version: '0'
391
+ - !ruby/object:Gem::Dependency
392
+ name: standardrb
393
+ requirement: !ruby/object:Gem::Requirement
394
+ requirements:
395
+ - - ">="
396
+ - !ruby/object:Gem::Version
397
+ version: '0'
398
+ type: :development
399
+ prerelease: false
400
+ version_requirements: !ruby/object:Gem::Requirement
401
+ requirements:
402
+ - - ">="
403
+ - !ruby/object:Gem::Version
404
+ version: '0'
391
405
  description: CSV Validator
392
406
  email:
393
407
  - pezholio@gmail.com
@@ -404,10 +418,13 @@ files:
404
418
  - ".github/dependabot.yml"
405
419
  - ".github/workflows/push.yml"
406
420
  - ".gitignore"
421
+ - ".pre-commit-hooks.yaml"
407
422
  - ".ruby-version"
423
+ - ".standard_todo.yml"
408
424
  - CHANGELOG.md
409
425
  - CODE_OF_CONDUCT.md
410
426
  - CONTRIBUTING.md
427
+ - Dockerfile
411
428
  - Gemfile
412
429
  - LICENSE.md
413
430
  - README.md
@@ -415,6 +432,7 @@ files:
415
432
  - bin/create_schema
416
433
  - bin/csvlint
417
434
  - csvlint.gemspec
435
+ - docker_notes_for_windows.txt
418
436
  - features/check_format.feature
419
437
  - features/cli.feature
420
438
  - features/csv_options.feature
@@ -495,65 +513,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
495
513
  version: '2.5'
496
514
  - - "<"
497
515
  - !ruby/object:Gem::Version
498
- version: '3.2'
516
+ version: '3.3'
499
517
  required_rubygems_version: !ruby/object:Gem::Requirement
500
518
  requirements:
501
519
  - - ">="
502
520
  - !ruby/object:Gem::Version
503
521
  version: '0'
504
522
  requirements: []
505
- rubygems_version: 3.3.7
523
+ rubygems_version: 3.4.1
506
524
  signing_key:
507
525
  specification_version: 4
508
526
  summary: CSV Validator
509
- test_files:
510
- - features/check_format.feature
511
- - features/cli.feature
512
- - features/csv_options.feature
513
- - features/csvupload.feature
514
- - features/csvw_schema_validation.feature
515
- - features/fixtures/cr-line-endings.csv
516
- - features/fixtures/crlf-line-endings.csv
517
- - features/fixtures/inconsistent-line-endings-unquoted.csv
518
- - features/fixtures/inconsistent-line-endings.csv
519
- - features/fixtures/invalid-byte-sequence.csv
520
- - features/fixtures/invalid_many_rows.csv
521
- - features/fixtures/lf-line-endings.csv
522
- - features/fixtures/spreadsheet.xls
523
- - features/fixtures/spreadsheet.xlsx
524
- - features/fixtures/title-row.csv
525
- - features/fixtures/valid.csv
526
- - features/fixtures/valid_many_rows.csv
527
- - features/fixtures/w3.org/.well-known/csvm
528
- - features/fixtures/white space in filename.csv
529
- - features/fixtures/windows-line-endings.csv
530
- - features/information.feature
531
- - features/parse_csv.feature
532
- - features/schema_validation.feature
533
- - features/sources.feature
534
- - features/step_definitions/cli_steps.rb
535
- - features/step_definitions/csv_options_steps.rb
536
- - features/step_definitions/information_steps.rb
537
- - features/step_definitions/parse_csv_steps.rb
538
- - features/step_definitions/schema_validation_steps.rb
539
- - features/step_definitions/sources_steps.rb
540
- - features/step_definitions/validation_errors_steps.rb
541
- - features/step_definitions/validation_info_steps.rb
542
- - features/step_definitions/validation_warnings_steps.rb
543
- - features/support/aruba.rb
544
- - features/support/earl_formatter.rb
545
- - features/support/env.rb
546
- - features/support/load_tests.rb
547
- - features/support/webmock.rb
548
- - features/validation_errors.feature
549
- - features/validation_info.feature
550
- - features/validation_warnings.feature
551
- - spec/csvw/column_spec.rb
552
- - spec/csvw/date_format_spec.rb
553
- - spec/csvw/number_format_spec.rb
554
- - spec/csvw/table_group_spec.rb
555
- - spec/csvw/table_spec.rb
556
- - spec/field_spec.rb
557
- - spec/schema_spec.rb
558
- - spec/spec_helper.rb
559
- - spec/validator_spec.rb
527
+ test_files: []