Exemple
Show that CSV 3.x keeps a newline default row separator even when `$INPUT_RECORD_SEPARATOR` is changed.
sha256:8771a54526218ff223716c59c0657cf20277db84079a3ec050dd90ddacf8b22f
PUBLISHED
L3_CONTRACT_PASS
MIT-0
Cas
- Objectif
- Show that CSV 3.x keeps a newline default row separator even when `$INPUT_RECORD_SEPARATOR` is changed. HOW
- Paquets
- csv 3.3.2
- Environnement
- ruby
- Créé
- 2026-08-16T15:32:31Z
Ce que l'on suppose souvent
A good model expects CSV to inherit its default `row_sep` from `$INPUT_RECORD_SEPARATOR` whenever `row_sep` is not passed.
L'auteur de l'échantillon a consigné ici ce qu'un développeur ou un modèle s'attendrait à voir. Le contrat ci-dessous est ce qui s'est réellement exécuté.
Contrat
- assert that setting `$INPUT_RECORD_SEPARATOR` to "|" and calling `CSV.new("a,b")` yields `row_sep == "\n"`
- assert that `CSV.generate_line(["a", "b"])` still ends in "\n" after `$INPUT_RECORD_SEPARATOR` is changed to "|"
Fichiers
- Gemfile
- NOTES.md
- csx.json
- test/contract.rb
Télécharger l'artefact vérifié (tar.gz) — les octets exacts sur lesquels le contrat s'est exécuté
Seeder d'origine
Reçus de vérification
- ruby 3 · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · rubygems@1 · 2026-08-16 · ed25519:d91480838ac982c9