Skip to content

Commit 7840178

Browse files
committed
docs: Improve test data documentation and fix typo
1 parent 89edca6 commit 7840178

1 file changed

Lines changed: 20 additions & 12 deletions

File tree

testdata/test_data.md

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
<!-- vim-markdown-toc GFM -->
66

77
* [Introduction](#introduction)
8+
* [Test Structure](#test-structure)
89
* [Tests](#tests)
910
* [Uninomials without authorship](#uninomials-without-authorship)
1011
* [Uninomials with authorship](#uninomials-with-authorship)
@@ -29,7 +30,7 @@
2930
* [Hybrid formulae](#hybrid-formulae)
3031
* [Graft-chimeras](#graft-chimeras)
3132
* [Genus with hyphen (allowed by ICN)](#genus-with-hyphen-allowed-by-icn)
32-
* [Misspeled name](#misspeled-name)
33+
* [Misspelled name](#misspelled-name)
3334
* [A 'basionym' author in parenthesis (basionym is an ICN term)](#a-basionym-author-in-parenthesis-basionym-is-an-icn-term)
3435
* [Infrageneric epithets (ICZN)](#infrageneric-epithets-iczn)
3536
* [Names with multiple dashes in specific epithet](#names-with-multiple-dashes-in-specific-epithet)
@@ -50,18 +51,25 @@
5051

5152
## Introduction
5253

53-
This test consists of a line-delimited input (scientific name), detailed
54-
parsed output in JSON format and simplified parsed output in
55-
pipe-delimited format
54+
This test suite validates scientific name parsing through structured test
55+
cases. Each test case provides an input scientific name with expected parsing
56+
results in JSON format.
5657

57-
Test Structure
58+
### Test Structure
5859

59-
The first line in every test is a scientific name to parse
60-
The second line corresponds to detailed JSON output from the gnparser
61-
The third line corresponds to pipe-delimited "simple" output. Simple output
62-
consists of name-string UUID v5, verbatim name-string, canonical form without
63-
ranks, canonical form with ranks, authorship of the most junior clade, year,
64-
parsing quality number
60+
Each test case follows a four-part format:
61+
62+
1. **Name:** The scientific name to be parsed (input)
63+
2. **Canonical:** Expected canonical form of the name
64+
3. **Authorship:** Expected authorship information
65+
4. **JSON Block:** Detailed parsing results from gnparser containing:
66+
- Parsing status and quality score
67+
- Verbatim and normalized name forms
68+
- Canonical forms (stemmed, simple, full)
69+
- Cardinality and taxonomic rank
70+
- Detailed authorship breakdown
71+
- Word-by-word parsing analysis
72+
- Unique name-string identifier
6573

6674
[Parsing quality](https://github.com/gnames/gnparser/quality.md)
6775

@@ -3162,7 +3170,7 @@ Authorship:
31623170
{"parsed":false,"quality":0,"verbatim":"Tsugo-piceo-piceo-picea × crassifolia","cardinality":0,"id":"0ab8c5ed-b224-5c17-9957-298a80cc07be","parserVersion":"test_version"}
31633171
```
31643172

3165-
### Misspeled name
3173+
### Misspelled name
31663174

31673175
Name: Ambrysus-Stål, 1862
31683176

0 commit comments

Comments
 (0)