Here is the test output, starting from a new check-out. AFAICT it's complaining about newlines at the end? But no matter how much I try to paste the "expected" into the files and fiddle with ending newlines (the only detectable difference) it keeps failing.
handrews@ixat src % mkdir new-oas
handrews@ixat src % git clone https://github.com/OAI/OpenAPI-Specification.git new-oas
Cloning into 'new-oas'...
remote: Enumerating objects: 16954, done.
remote: Counting objects: 100% (783/783), done.
remote: Compressing objects: 100% (327/327), done.
remote: Total 16954 (delta 691), reused 467 (delta 456), pack-reused 16171 (from 4)
Receiving objects: 100% (16954/16954), 7.66 MiB | 25.88 MiB/s, done.
Resolving deltas: 100% (10109/10109), done.
handrews@ixat src % cd new-oas handrews@ixat new-oas % npm install
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: 'undici@7.10.0',
npm WARN EBADENGINE required: { node: '>=20.18.1' },
npm WARN EBADENGINE current: { node: 'v20.12.1', npm: '10.5.0' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: 'yargs@18.0.0',
npm WARN EBADENGINE required: { node: '^20.19.0 || ^22.12.0 || >=23' },
npm WARN EBADENGINE current: { node: 'v20.12.1', npm: '10.5.0' }
npm WARN EBADENGINE }
npm WARN EBADENGINE Unsupported engine {
npm WARN EBADENGINE package: 'yargs-parser@22.0.0',
npm WARN EBADENGINE required: { node: '^20.19.0 || ^22.12.0 || >=23' },
npm WARN EBADENGINE current: { node: 'v20.12.1', npm: '10.5.0' }
npm WARN EBADENGINE }
added 359 packages, and audited 360 packages in 2s
112 packages are looking for funding
run `npm fund` for details
6 vulnerabilities (5 low, 1 high)
To address issues that do not require attention, run:
npm audit fix
To address all issues (including breaking changes), run:
npm audit fix --force
Run `npm audit` for details.
handrews@ixat new-oas % gc v3.2-dev
branch 'v3.2-dev' set up to track 'origin/v3.2-dev'.
Switched to a new branch 'v3.2-dev'
handrews@ixat new-oas % npm test
> oas-infra@0.0.0 test
> c8 --100 vitest --watch=false && bash scripts/schema-test-coverage.sh
RUN v3.2.3 /Users/handrews/src/new-oas
✓ _archive_/schemas/v3.0/schema.test.mjs (6 tests) 30ms
✓ tests/schema/schema.test.mjs (36 tests) 170ms
❯ tests/md2html/md2html.test.mjs (2 tests | 2 failed) 621ms
× md2html > basic-new.md 366ms
→ expected '' to equal '<!DOCTYPE html><htmllang="en"><head>…'
× md2html > basic-old.md 254ms
→ expected '' to equal '<!DOCTYPE html><htmllang="en"><head>…'
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Failed Tests 2 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯
FAIL tests/md2html/md2html.test.mjs > md2html > basic-new.md
FAIL tests/md2html/md2html.test.mjs > md2html > basic-old.md
AssertionError: expected '' to equal '<!DOCTYPE html><htmllang="en"><head>…'
- Expected
+ Received
- <!DOCTYPE html><htmllang="en"><head>
- <!-- Global site tag (gtag.js) - Google Analytics -->
- <scriptasyncsrc="https://www.googletagmanager.com/gtag/js?id=UA-831873-42"></script>
- <script>-window.dataLayer=window.dataLayer||[];-functiongtag(){dataLayer.push(arguments);}-gtag('js',newDate());-gtag('config','UA-831873-42');-</script>
- <metacharset="UTF-8">
- <title>OpenAPI Specification v30.0.1 | Introduction, Definitions, & More</title><metaname="description" content="The OpenAPI Specification (OAS) defines a standard, programming language-agnostic interface description for HTTP APIs.">
- <metaname="color-scheme" content="light dark"><scriptsrc="../js/respec-w3c.js" class="remove"></script><scriptclass="remove">varrespecConfig={"specStatus":"base","latestVersion":"https://spec.openapis.org/oas/latest.html","thisVersion":"https://spec.openapis.org/oas/v30.0.1.html","canonicalURI":"https://spec.openapis.org/oas/v30.0.1.html","editors":[{"name":"John Doe "},{"name":"Jane Doe "}],"formerEditors":[{"name":"Foo Bar "}],"publishDate":"3001-04-01T00:00:00.000Z","subtitle":"Version 30.0.1","edDraftURI":"https://github.com/OAI/OpenAPI-Specification/","shortName":"OAS","historyURI":null,"lint":false,"logos":[{"src":"https://raw.githubusercontent.com/OAI/OpenAPI-Style-Guide/master/graphics/bitmap/OpenAPI_Logo_Pantone.png","alt":"OpenAPI Initiative","height":48,"url":"https://openapis.org/"}],"otherLinks":[{"key":"Other versions:","data":[{"href":"https://spec.openapis.org/oas/v31.0.0.html"},{"href":"https://spec.openapis.org/oas/v30.0.0.html"}]},{"key":"Participate","data":[{"value":"GitHub OAI/OpenAPI-Specification","href":"https://github.com/OAI/OpenAPI-Specification/"},{"value":"File a bug","href":"https://github.com/OAI/OpenAPI-Specification/issues"},{"value":"Commit history","href":"https://github.com/OAI/OpenAPI-Specification/commits/main/versions/30.0.1.md"},{"value":"Pull requests","href":"https://github.com/OAI/OpenAPI-Specification/pulls"}]}]};</script>
- </head>
- <body><style>#respec-ui { visibility: hidden; } #title { color:#578000; } #subtitle { color:#578000; } .dt-published { color:#578000; } .dt-published::before { content:"Published "; } h1,h2,h3,h4,h5,h6 { color:#578000; font-weight: normal; font-style: normal; } a[href] { color:#45512c; } body:not(.toc-inline) #toch2 { color:#45512c; } table { display: block; width:100%; overflow: auto; } tableth { font-weight:600; } tableth,tabletd { padding:6px13px; border:1px solid #dfe2e5; } tabletr { background-color:#fff; border-top:1px solid #c6cbd1; } tabletr:nth-child(2n) { background-color:#f6f8fa; } pre { background-color:#f6f8fa!important; } code { color:#c83500 } thcode { color: inherit } a.bibref { text-decoration: underline; } body.darkmode { --toclink-underline:#6a9000; --toclink-visited-underline:#fff; } body.darkmodea,body.darkmode .tocxref,body.darkmode .u-url { color:#6a9000; } body.darkmodecode { color:#e66c33; } body.darkmode:not(.toc-inline) #toch2,body.darkmodeh1,body.darkmodeh2,body.darkmodeh3,body.darkmodeh4,body.darkmodeh5,body.darkmodeh6,body.darkmode#title,body.darkmode#subtitle,body.darkmode .toc-inline,body.darkmode .dt-published { color:#7bb01c; } body.darkmodepre,body.darkmodetabletr:nth-child(2n),body.darkmodetabletr { background-color:#1e1e1e!important; color:#dcdcdc; } body.darkmodeimg { background: transparent; } body.darkmode .logoimg { display: none; } body.darkmode .logo::before { content:""; display: inline-block; height:48px; width:175px; background:url("https://raw.githubusercontent.com/OAI/OpenAPI-Style-Guide/refs/heads/main/graphics/bitmap/OpenAPI_Logo_Pantone.png") no-repeat center / contain; vertical-align: middle; } /** This contains the content of the https://www.w3.org/StyleSheets/TR/2021/dark.css file */body.darkmode { --text:#ddd; --bg: black; /* Absolute URLs due to https://bugs.webkit.org/show_bug.cgi?id=230243 */--unofficial-watermark:url(https://www.w3.org/StyleSheets/TR/2021/logos/UD-watermark-dark-unofficial); --draft-watermark:url(https://www.w3.org/StyleSheets/TR/2021/logos/UD-watermark-dark-draft); --logo-bg:#1a5e9a; --logo-active-bg:#c00; --logo-text: white; --tocnav-normal-text:#999; --tocnav-normal-bg:var(--bg); --tocnav-hover-text:var(--tocnav-normal-text); --tocnav-hover-bg:#080808; --tocnav-active-text:#f44; --tocnav-active-bg:var(--tocnav-normal-bg); --tocsidebar-text:var(--text); --tocsidebar-bg:#080808; --tocsidebar-shadow:rgba(255,255,255,.1); --tocsidebar-heading-text:hsla(203,20%,40%,.7); --toclink-text:var(--text); --toclink-underline:#6af; --toclink-visited-text:var(--toclink-text); --toclink-visited-underline:#054572; --heading-text:#8af; --hr-text:var(--text); --algo-border:#456; --del-text:#f44; --del-bg: transparent; --ins-text:#4a4; --ins-bg: transparent; --a-normal-text:#6af; --a-normal-underline:#555; --a-visited-text:var(--a-normal-text); --a-visited-underline:var(--a-normal-underline); --a-hover-bg:rgba(25%,25%,25%,.2); --a-active-text:#f44; --a-active-underline:var(--a-active-text); --borderedblock-bg:rgba(255,255,255,.05); --blockquote-border: silver; --blockquote-bg:var(--borderedblock-bg); --blockquote-text: currentcolor; --issue-border:#e05252; --issue-bg:var(--borderedblock-bg); --issue-text:var(--text); --issueheading-text:hsl(0deg,70%,70%); --example-border:hsl(50deg,90%,60%); --example-bg:var(--borderedblock-bg); --example-text:var(--text); --exampleheading-text:hsl(50deg,70%,70%); --note-border:hsl(120deg,100%,35%); --note-bg:var(--borderedblock-bg); --note-text:var(--text); --noteheading-text:hsl(120,70%,70%); --notesummary-underline: silver; --advisement-border: orange; --advisement-bg:#222218; --advisement-text:var(--text); --advisementheading-text:#f84; --amendment-border:#330099; --amendment-bg:var(--borderedblock-bg); --amendment-text:var(--text); --amendmentheading-text:#a086ff; --amendment-border:#330099; --amendment-bg:#080010; --amendment-text:var(--text); --amendmentheading-text:#cc00ff; --warning-border: red; --warning-bg:hsla(40,100%,20%,0.95); --warning-text:var(--text); --def-border:#8ccbf2; --def-bg:#080818; --def-text:var(--text); --defrow-border:#136; --datacell-border: silver; --indexinfo-text:#aaa; --indextable-hover-text:var(--text); --indextable-hover-bg:#181818; --outdatedspec-bg:rgba(255,255,255,.5); --outdatedspec-text: black; --outdated-bg: maroon; --outdated-text: white; --outdated-shadow: red; --editedrec-bg: darkorange; }/** * GitHub Gist Theme * Author : Louis Barranqueiro - https://github.com/LouisBarranqueiro */ .hljs { display: block; background: white; padding:0.5em; color:#333333; overflow-x: auto; } .hljs-comment, .hljs-meta { color:#727070; } .hljs-string, .hljs-variable, .hljs-template-variable, .hljs-strong, .hljs-emphasis, .hljs-quote { color:#c74700; } .hljs-number { color:#005e5e; } .hljs-keyword, .hljs-selector-tag, .hljs-type { color:#a71d5d; } .hljs-literal, .hljs-symbol, .hljs-bullet, .hljs-attribute { color:#007aa2; } .hljs-section, .hljs-name { color:#4b7c46; } .hljs-tag { color:#333333; } .hljs-title, .hljs-attr, .hljs-selector-id, .hljs-selector-class, .hljs-selector-attr, .hljs-selector-pseudo { color:#795da3; } .hljs-addition { color:#55a532; background-color:#eaffea; } .hljs-deletion { color:#bd2c00; background-color:#ffecec; } .hljs-link { text-decoration: underline; } </style><h1id="title">OpenAPI Specification v30.0.1 </h1><pclass="copyright">Copyright © 3001 the Linux Foundation</p><sectionclass="notoc" id="abstract"><h2>What is the OpenAPI Specification?</h2>The OpenAPI Specification (OAS) defines a standard, programming language-agnostic interface description for HTTP APIs, which allows both humans and computers to discover and understand the capabilities of a service without requiring access to source code, additional documentation, or inspection of network traffic. When properly defined via OpenAPI, a consumer can understand and interact with the remote service with a minimal amount of implementation logic. Similar to what interface descriptions have done for lower-level programming, the OpenAPI Specification removes guesswork in calling a service.</section><sectionclass="override" id="sotd" data-max-toc="0"><h2>Status of This Document</h2>The source-of-truth for this specification is the HTML file referenced above as <em>This version</em>.</section>
- <section><h1>Heading 1</h1>
- <p>Text for first chapter</p>
- <sectionclass="override" id="conformance"><h2>Version 30.0.1</h2>
- <p>This is the conformance section</p>
- </section></section><section><h1>Heading 2</h1>
- <p>Text for <spanid="first-anchor"></span>first section</p>
- </section><section><h1><dfn>Definitions</dfn></h1>
- <section><h2><dfn>Foo</dfn></h2>
- <p>Definition of Foo.</p>
- </section></section><section><h1>Another Heading 2</h1>
- <p>Text for second section</p>
- <p><ahref="https://learn.openapis.org/examples/foo.html">Relative link to example</a></p>
- <p><ahref="https://github.com/OAI/OpenAPI-Specification/tree/main/something/else">Relative link to something else</a></p>
- <section><h2>Heading 3</h2>
- <p>Text for first subsection</p>
- <p>[[RFC3986]]</p>
- <p>[[RFC9110]] <ahref="https://datatracker.ietf.org/doc/html/rfc9110#section-4">Section 4</a></p>
- <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-punctuation">{</span>
- <spanclass="hljs-attr">"foo"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-literal"><spanclass="hljs-keyword">true</span></span>
- <spanclass="hljs-punctuation">}</span>
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-attr">foo:</span><spanclass="hljs-literal">true</span>
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code>text/plain
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code>no language
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code>unknown language
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code>https://<spanclass="hljs-attr">foo.com</span>/<spanclass="hljs-attr">bar</span>?<spanclass="hljs-attr">baz</span>=<spanclass="hljs-literal">qux</span>&<spanclass="hljs-attr">fred</span>=<spanclass="hljs-literal">waldo</span>#<spanclass="hljs-attr">fragment</span>
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code>https://foo.com/bar{<spanclass="hljs-attr">?baz*</span>,<spanclass="hljs-attr">qux</span>}
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-meta">--boundary-example</span>
- <spanclass="hljs-literal">Content-Type:<spanclass="hljs-attr"> application/openapi+yaml</span></span>
- <spanclass="hljs-literal">Content-Location:<spanclass="hljs-attr"> https://inaccessible-domain.com/api/openapi.yaml</span></span>
-
- openapi: 3.2.0
- info:
- title: Example API
- version: 1.0
- externalDocs:
- url: docs.html
-
- <spanclass="hljs-meta">--boundary-example</span>
- <spanclass="hljs-literal">Content-Type:<spanclass="hljs-attr"> text/html</span></span>
- <spanclass="hljs-literal">Content-Location:<spanclass="hljs-attr"> https://example.com/api/docs.html</span></span>
-
- <html>
- <head>
- <title>API Documentation</title>
- </head>
- <body>
- <p>Awesome documentation goes here</p>
- </body>
- </html>
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-attr">event</span>: addString
- <spanclass="hljs-attr">data</span>: This data is formatted
- <spanclass="hljs-attr">data</span>: across two lines
- <spanclass="hljs-attr">retry</span>: 5
- <spanclass="hljs-attr">
- event</span>: addNumber
- <spanclass="hljs-attr">data</span>: 1234.5678
- <spanclass="hljs-attr">unknownField</span>: this is ignored
- <spanclass="hljs-attr">
- </span><spanclass="hljs-comment">: This is a comment</span>
- <spanclass="hljs-attr">event</span>: addJSON
- <spanclass="hljs-attr">data</span>: {"foo": 42}
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addString"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"This data is formatted\nacross two lines"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"retry"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">5</span><spanclass="hljs-punctuation">}</span>
- <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addNumber"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1234.5678"</span><spanclass="hljs-punctuation">}</span>
- <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addJSON"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"{\"foo\": 42}"</span><spanclass="hljs-punctuation">}</span>
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addString"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"This data is formatted\nacross two lines"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"retry"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">5</span><spanclass="hljs-punctuation">}</span>
- <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addNumber"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1234.5678"</span><spanclass="hljs-punctuation">}</span>
- <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addJSON"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"{\"foo\": 42}"</span><spanclass="hljs-punctuation">}</span>
- </code></pre>
- <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-meta">0x1E</span><spanclass="hljs-punctuation">{</span>
- <spanclass="hljs-attr">"timestamp"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1985-04-12T23:20:50.52Z"</span><spanclass="hljs-punctuation">,</span>
- <spanclass="hljs-attr">"level"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">1</span><spanclass="hljs-punctuation">,</span>
- <spanclass="hljs-attr">"message"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"Hi!"</span>
- <spanclass="hljs-punctuation">}</span>
- <spanclass="hljs-meta">0x1E</span><spanclass="hljs-punctuation">{</span>
- <spanclass="hljs-attr">"timestamp"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1985-04-12T23:20:51.37Z"</span><spanclass="hljs-punctuation">,</span>
- <spanclass="hljs-attr">"level"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">1</span><spanclass="hljs-punctuation">,</span>
- <spanclass="hljs-attr">"message"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"Bye!"</span>
- <spanclass="hljs-punctuation">}</span>
- </code></pre>
- </section></section><sectionclass="appendix"><h1>Appendix A: Revision History</h1>
- <table>
- <thead>
- <tr>
- <th>Version</th>
- <th>Date</th>
- </tr>
- </thead>
- <tbody>
- <tr>
- <td>30.0.1</td>
- <td>3001-04-01</td>
- </tr>
- </tbody>
- </table>
-
-
❯ tests/md2html/md2html.test.mjs:26:34
24| folder,
25| );
26| expect(output.stdout).to.equal(expected);
| ^
27| });
28| });
⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/2]⎯
Test Files 1 failed | 2 passed (3)
Tests 2 failed | 42 passed (44)
Start at 12:37:21
Duration 836ms (transform 39ms, setup 0ms, collect 434ms, tests 821ms, environment 0ms, prepare 137ms)
------------|---------|----------|---------|---------|----------------------------------------
File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s ------------|---------|----------|---------|---------|----------------------------------------
All files | 33.87 | 87.5 | 0 | 33.87 | md2html.js | 33.87 | 87.5 | 0 | 33.87 | ...169,172-255,257-272,274-293,296-490 ------------|---------|----------|---------|---------|----------------------------------------
ERROR: Coverage for lines (33.87%) does not meet global threshold (100%)
ERROR: Coverage for functions (0%) does not meet global threshold (100%)
ERROR: Coverage for branches (87.5%) does not meet global threshold (100%)
ERROR: Coverage for statements (33.87%) does not meet global threshold (100%)
handrews@ixat new-oas % This was run at the last prompt of the previous session, I just split it for readability:
After the last updates (which I merged b/c @ralfhandl did the very helpful thing of posting test PRs to show it would work), I now can't get tests to pass or the spec to build.
Test output
Here is the test output, starting from a new check-out. AFAICT it's complaining about newlines at the end? But no matter how much I try to paste the "expected" into the files and fiddle with ending newlines (the only detectable difference) it keeps failing.
handrews@ixat src % mkdir new-oas handrews@ixat src % git clone https://github.com/OAI/OpenAPI-Specification.git new-oas Cloning into 'new-oas'... remote: Enumerating objects: 16954, done. remote: Counting objects: 100% (783/783), done. remote: Compressing objects: 100% (327/327), done. remote: Total 16954 (delta 691), reused 467 (delta 456), pack-reused 16171 (from 4) Receiving objects: 100% (16954/16954), 7.66 MiB | 25.88 MiB/s, done. Resolving deltas: 100% (10109/10109), done. handrews@ixat src % cd new-oas handrews@ixat new-oas % npm install npm WARN EBADENGINE Unsupported engine { npm WARN EBADENGINE package: 'undici@7.10.0', npm WARN EBADENGINE required: { node: '>=20.18.1' }, npm WARN EBADENGINE current: { node: 'v20.12.1', npm: '10.5.0' } npm WARN EBADENGINE } npm WARN EBADENGINE Unsupported engine { npm WARN EBADENGINE package: 'yargs@18.0.0', npm WARN EBADENGINE required: { node: '^20.19.0 || ^22.12.0 || >=23' }, npm WARN EBADENGINE current: { node: 'v20.12.1', npm: '10.5.0' } npm WARN EBADENGINE } npm WARN EBADENGINE Unsupported engine { npm WARN EBADENGINE package: 'yargs-parser@22.0.0', npm WARN EBADENGINE required: { node: '^20.19.0 || ^22.12.0 || >=23' }, npm WARN EBADENGINE current: { node: 'v20.12.1', npm: '10.5.0' } npm WARN EBADENGINE } added 359 packages, and audited 360 packages in 2s 112 packages are looking for funding run `npm fund` for details 6 vulnerabilities (5 low, 1 high) To address issues that do not require attention, run: npm audit fix To address all issues (including breaking changes), run: npm audit fix --force Run `npm audit` for details. handrews@ixat new-oas % gc v3.2-dev branch 'v3.2-dev' set up to track 'origin/v3.2-dev'. Switched to a new branch 'v3.2-dev' handrews@ixat new-oas % npm test > oas-infra@0.0.0 test > c8 --100 vitest --watch=false && bash scripts/schema-test-coverage.sh RUN v3.2.3 /Users/handrews/src/new-oas ✓ _archive_/schemas/v3.0/schema.test.mjs (6 tests) 30ms ✓ tests/schema/schema.test.mjs (36 tests) 170ms ❯ tests/md2html/md2html.test.mjs (2 tests | 2 failed) 621ms × md2html > basic-new.md 366ms → expected '' to equal '<!DOCTYPE html><htmllang="en"><head>…' × md2html > basic-old.md 254ms → expected '' to equal '<!DOCTYPE html><htmllang="en"><head>…' ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ Failed Tests 2 ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯ FAIL tests/md2html/md2html.test.mjs > md2html > basic-new.md FAIL tests/md2html/md2html.test.mjs > md2html > basic-old.md AssertionError: expected '' to equal '<!DOCTYPE html><htmllang="en"><head>…' - Expected + Received - <!DOCTYPE html><htmllang="en"><head> - <!-- Global site tag (gtag.js) - Google Analytics --> - <scriptasyncsrc="https://www.googletagmanager.com/gtag/js?id=UA-831873-42"></script> - <script>-window.dataLayer=window.dataLayer||[];-functiongtag(){dataLayer.push(arguments);}-gtag('js',newDate());-gtag('config','UA-831873-42');-</script> - <metacharset="UTF-8"> - <title>OpenAPI Specification v30.0.1 | Introduction, Definitions, & More</title><metaname="description" content="The OpenAPI Specification (OAS) defines a standard, programming language-agnostic interface description for HTTP APIs."> - <metaname="color-scheme" content="light dark"><scriptsrc="../js/respec-w3c.js" class="remove"></script><scriptclass="remove">varrespecConfig={"specStatus":"base","latestVersion":"https://spec.openapis.org/oas/latest.html","thisVersion":"https://spec.openapis.org/oas/v30.0.1.html","canonicalURI":"https://spec.openapis.org/oas/v30.0.1.html","editors":[{"name":"John Doe "},{"name":"Jane Doe "}],"formerEditors":[{"name":"Foo Bar "}],"publishDate":"3001-04-01T00:00:00.000Z","subtitle":"Version 30.0.1","edDraftURI":"https://github.com/OAI/OpenAPI-Specification/","shortName":"OAS","historyURI":null,"lint":false,"logos":[{"src":"https://raw.githubusercontent.com/OAI/OpenAPI-Style-Guide/master/graphics/bitmap/OpenAPI_Logo_Pantone.png","alt":"OpenAPI Initiative","height":48,"url":"https://openapis.org/"}],"otherLinks":[{"key":"Other versions:","data":[{"href":"https://spec.openapis.org/oas/v31.0.0.html"},{"href":"https://spec.openapis.org/oas/v30.0.0.html"}]},{"key":"Participate","data":[{"value":"GitHub OAI/OpenAPI-Specification","href":"https://github.com/OAI/OpenAPI-Specification/"},{"value":"File a bug","href":"https://github.com/OAI/OpenAPI-Specification/issues"},{"value":"Commit history","href":"https://github.com/OAI/OpenAPI-Specification/commits/main/versions/30.0.1.md"},{"value":"Pull requests","href":"https://github.com/OAI/OpenAPI-Specification/pulls"}]}]};</script> - </head> - <body><style>#respec-ui { visibility: hidden; } #title { color:#578000; } #subtitle { color:#578000; } .dt-published { color:#578000; } .dt-published::before { content:"Published "; } h1,h2,h3,h4,h5,h6 { color:#578000; font-weight: normal; font-style: normal; } a[href] { color:#45512c; } body:not(.toc-inline) #toch2 { color:#45512c; } table { display: block; width:100%; overflow: auto; } tableth { font-weight:600; } tableth,tabletd { padding:6px13px; border:1px solid #dfe2e5; } tabletr { background-color:#fff; border-top:1px solid #c6cbd1; } tabletr:nth-child(2n) { background-color:#f6f8fa; } pre { background-color:#f6f8fa!important; } code { color:#c83500 } thcode { color: inherit } a.bibref { text-decoration: underline; } body.darkmode { --toclink-underline:#6a9000; --toclink-visited-underline:#fff; } body.darkmodea,body.darkmode .tocxref,body.darkmode .u-url { color:#6a9000; } body.darkmodecode { color:#e66c33; } body.darkmode:not(.toc-inline) #toch2,body.darkmodeh1,body.darkmodeh2,body.darkmodeh3,body.darkmodeh4,body.darkmodeh5,body.darkmodeh6,body.darkmode#title,body.darkmode#subtitle,body.darkmode .toc-inline,body.darkmode .dt-published { color:#7bb01c; } body.darkmodepre,body.darkmodetabletr:nth-child(2n),body.darkmodetabletr { background-color:#1e1e1e!important; color:#dcdcdc; } body.darkmodeimg { background: transparent; } body.darkmode .logoimg { display: none; } body.darkmode .logo::before { content:""; display: inline-block; height:48px; width:175px; background:url("https://raw.githubusercontent.com/OAI/OpenAPI-Style-Guide/refs/heads/main/graphics/bitmap/OpenAPI_Logo_Pantone.png") no-repeat center / contain; vertical-align: middle; } /** This contains the content of the https://www.w3.org/StyleSheets/TR/2021/dark.css file */body.darkmode { --text:#ddd; --bg: black; /* Absolute URLs due to https://bugs.webkit.org/show_bug.cgi?id=230243 */--unofficial-watermark:url(https://www.w3.org/StyleSheets/TR/2021/logos/UD-watermark-dark-unofficial); --draft-watermark:url(https://www.w3.org/StyleSheets/TR/2021/logos/UD-watermark-dark-draft); --logo-bg:#1a5e9a; --logo-active-bg:#c00; --logo-text: white; --tocnav-normal-text:#999; --tocnav-normal-bg:var(--bg); --tocnav-hover-text:var(--tocnav-normal-text); --tocnav-hover-bg:#080808; --tocnav-active-text:#f44; --tocnav-active-bg:var(--tocnav-normal-bg); --tocsidebar-text:var(--text); --tocsidebar-bg:#080808; --tocsidebar-shadow:rgba(255,255,255,.1); --tocsidebar-heading-text:hsla(203,20%,40%,.7); --toclink-text:var(--text); --toclink-underline:#6af; --toclink-visited-text:var(--toclink-text); --toclink-visited-underline:#054572; --heading-text:#8af; --hr-text:var(--text); --algo-border:#456; --del-text:#f44; --del-bg: transparent; --ins-text:#4a4; --ins-bg: transparent; --a-normal-text:#6af; --a-normal-underline:#555; --a-visited-text:var(--a-normal-text); --a-visited-underline:var(--a-normal-underline); --a-hover-bg:rgba(25%,25%,25%,.2); --a-active-text:#f44; --a-active-underline:var(--a-active-text); --borderedblock-bg:rgba(255,255,255,.05); --blockquote-border: silver; --blockquote-bg:var(--borderedblock-bg); --blockquote-text: currentcolor; --issue-border:#e05252; --issue-bg:var(--borderedblock-bg); --issue-text:var(--text); --issueheading-text:hsl(0deg,70%,70%); --example-border:hsl(50deg,90%,60%); --example-bg:var(--borderedblock-bg); --example-text:var(--text); --exampleheading-text:hsl(50deg,70%,70%); --note-border:hsl(120deg,100%,35%); --note-bg:var(--borderedblock-bg); --note-text:var(--text); --noteheading-text:hsl(120,70%,70%); --notesummary-underline: silver; --advisement-border: orange; --advisement-bg:#222218; --advisement-text:var(--text); --advisementheading-text:#f84; --amendment-border:#330099; --amendment-bg:var(--borderedblock-bg); --amendment-text:var(--text); --amendmentheading-text:#a086ff; --amendment-border:#330099; --amendment-bg:#080010; --amendment-text:var(--text); --amendmentheading-text:#cc00ff; --warning-border: red; --warning-bg:hsla(40,100%,20%,0.95); --warning-text:var(--text); --def-border:#8ccbf2; --def-bg:#080818; --def-text:var(--text); --defrow-border:#136; --datacell-border: silver; --indexinfo-text:#aaa; --indextable-hover-text:var(--text); --indextable-hover-bg:#181818; --outdatedspec-bg:rgba(255,255,255,.5); --outdatedspec-text: black; --outdated-bg: maroon; --outdated-text: white; --outdated-shadow: red; --editedrec-bg: darkorange; }/** * GitHub Gist Theme * Author : Louis Barranqueiro - https://github.com/LouisBarranqueiro */ .hljs { display: block; background: white; padding:0.5em; color:#333333; overflow-x: auto; } .hljs-comment, .hljs-meta { color:#727070; } .hljs-string, .hljs-variable, .hljs-template-variable, .hljs-strong, .hljs-emphasis, .hljs-quote { color:#c74700; } .hljs-number { color:#005e5e; } .hljs-keyword, .hljs-selector-tag, .hljs-type { color:#a71d5d; } .hljs-literal, .hljs-symbol, .hljs-bullet, .hljs-attribute { color:#007aa2; } .hljs-section, .hljs-name { color:#4b7c46; } .hljs-tag { color:#333333; } .hljs-title, .hljs-attr, .hljs-selector-id, .hljs-selector-class, .hljs-selector-attr, .hljs-selector-pseudo { color:#795da3; } .hljs-addition { color:#55a532; background-color:#eaffea; } .hljs-deletion { color:#bd2c00; background-color:#ffecec; } .hljs-link { text-decoration: underline; } </style><h1id="title">OpenAPI Specification v30.0.1 </h1><pclass="copyright">Copyright © 3001 the Linux Foundation</p><sectionclass="notoc" id="abstract"><h2>What is the OpenAPI Specification?</h2>The OpenAPI Specification (OAS) defines a standard, programming language-agnostic interface description for HTTP APIs, which allows both humans and computers to discover and understand the capabilities of a service without requiring access to source code, additional documentation, or inspection of network traffic. When properly defined via OpenAPI, a consumer can understand and interact with the remote service with a minimal amount of implementation logic. Similar to what interface descriptions have done for lower-level programming, the OpenAPI Specification removes guesswork in calling a service.</section><sectionclass="override" id="sotd" data-max-toc="0"><h2>Status of This Document</h2>The source-of-truth for this specification is the HTML file referenced above as <em>This version</em>.</section> - <section><h1>Heading 1</h1> - <p>Text for first chapter</p> - <sectionclass="override" id="conformance"><h2>Version 30.0.1</h2> - <p>This is the conformance section</p> - </section></section><section><h1>Heading 2</h1> - <p>Text for <spanid="first-anchor"></span>first section</p> - </section><section><h1><dfn>Definitions</dfn></h1> - <section><h2><dfn>Foo</dfn></h2> - <p>Definition of Foo.</p> - </section></section><section><h1>Another Heading 2</h1> - <p>Text for second section</p> - <p><ahref="https://learn.openapis.org/examples/foo.html">Relative link to example</a></p> - <p><ahref="https://github.com/OAI/OpenAPI-Specification/tree/main/something/else">Relative link to something else</a></p> - <section><h2>Heading 3</h2> - <p>Text for first subsection</p> - <p>[[RFC3986]]</p> - <p>[[RFC9110]] <ahref="https://datatracker.ietf.org/doc/html/rfc9110#section-4">Section 4</a></p> - <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-punctuation">{</span> - <spanclass="hljs-attr">"foo"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-literal"><spanclass="hljs-keyword">true</span></span> - <spanclass="hljs-punctuation">}</span> - </code></pre> - <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-attr">foo:</span><spanclass="hljs-literal">true</span> - </code></pre> - <preclass="nohighlight" tabindex="0"><code>text/plain - </code></pre> - <preclass="nohighlight" tabindex="0"><code>no language - </code></pre> - <preclass="nohighlight" tabindex="0"><code>unknown language - </code></pre> - <preclass="nohighlight" tabindex="0"><code>https://<spanclass="hljs-attr">foo.com</span>/<spanclass="hljs-attr">bar</span>?<spanclass="hljs-attr">baz</span>=<spanclass="hljs-literal">qux</span>&<spanclass="hljs-attr">fred</span>=<spanclass="hljs-literal">waldo</span>#<spanclass="hljs-attr">fragment</span> - </code></pre> - <preclass="nohighlight" tabindex="0"><code>https://foo.com/bar{<spanclass="hljs-attr">?baz*</span>,<spanclass="hljs-attr">qux</span>} - </code></pre> - <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-meta">--boundary-example</span> - <spanclass="hljs-literal">Content-Type:<spanclass="hljs-attr"> application/openapi+yaml</span></span> - <spanclass="hljs-literal">Content-Location:<spanclass="hljs-attr"> https://inaccessible-domain.com/api/openapi.yaml</span></span> - - openapi: 3.2.0 - info: - title: Example API - version: 1.0 - externalDocs: - url: docs.html - - <spanclass="hljs-meta">--boundary-example</span> - <spanclass="hljs-literal">Content-Type:<spanclass="hljs-attr"> text/html</span></span> - <spanclass="hljs-literal">Content-Location:<spanclass="hljs-attr"> https://example.com/api/docs.html</span></span> - - <html> - <head> - <title>API Documentation</title> - </head> - <body> - <p>Awesome documentation goes here</p> - </body> - </html> - </code></pre> - <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-attr">event</span>: addString - <spanclass="hljs-attr">data</span>: This data is formatted - <spanclass="hljs-attr">data</span>: across two lines - <spanclass="hljs-attr">retry</span>: 5 - <spanclass="hljs-attr"> - event</span>: addNumber - <spanclass="hljs-attr">data</span>: 1234.5678 - <spanclass="hljs-attr">unknownField</span>: this is ignored - <spanclass="hljs-attr"> - </span><spanclass="hljs-comment">: This is a comment</span> - <spanclass="hljs-attr">event</span>: addJSON - <spanclass="hljs-attr">data</span>: {"foo": 42} - </code></pre> - <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addString"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"This data is formatted\nacross two lines"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"retry"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">5</span><spanclass="hljs-punctuation">}</span> - <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addNumber"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1234.5678"</span><spanclass="hljs-punctuation">}</span> - <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addJSON"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"{\"foo\": 42}"</span><spanclass="hljs-punctuation">}</span> - </code></pre> - <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addString"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"This data is formatted\nacross two lines"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"retry"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">5</span><spanclass="hljs-punctuation">}</span> - <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addNumber"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1234.5678"</span><spanclass="hljs-punctuation">}</span> - <spanclass="hljs-punctuation">{</span><spanclass="hljs-attr">"event"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"addJSON"</span><spanclass="hljs-punctuation">,</span><spanclass="hljs-attr">"data"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"{\"foo\": 42}"</span><spanclass="hljs-punctuation">}</span> - </code></pre> - <preclass="nohighlight" tabindex="0"><code><spanclass="hljs-meta">0x1E</span><spanclass="hljs-punctuation">{</span> - <spanclass="hljs-attr">"timestamp"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1985-04-12T23:20:50.52Z"</span><spanclass="hljs-punctuation">,</span> - <spanclass="hljs-attr">"level"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">1</span><spanclass="hljs-punctuation">,</span> - <spanclass="hljs-attr">"message"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"Hi!"</span> - <spanclass="hljs-punctuation">}</span> - <spanclass="hljs-meta">0x1E</span><spanclass="hljs-punctuation">{</span> - <spanclass="hljs-attr">"timestamp"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"1985-04-12T23:20:51.37Z"</span><spanclass="hljs-punctuation">,</span> - <spanclass="hljs-attr">"level"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-number">1</span><spanclass="hljs-punctuation">,</span> - <spanclass="hljs-attr">"message"</span><spanclass="hljs-punctuation">:</span><spanclass="hljs-string">"Bye!"</span> - <spanclass="hljs-punctuation">}</span> - </code></pre> - </section></section><sectionclass="appendix"><h1>Appendix A: Revision History</h1> - <table> - <thead> - <tr> - <th>Version</th> - <th>Date</th> - </tr> - </thead> - <tbody> - <tr> - <td>30.0.1</td> - <td>3001-04-01</td> - </tr> - </tbody> - </table> - - ❯ tests/md2html/md2html.test.mjs:26:34 24| folder, 25| ); 26| expect(output.stdout).to.equal(expected); | ^ 27| }); 28| }); ⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯⎯[1/2]⎯ Test Files 1 failed | 2 passed (3) Tests 2 failed | 42 passed (44) Start at 12:37:21 Duration 836ms (transform 39ms, setup 0ms, collect 434ms, tests 821ms, environment 0ms, prepare 137ms) ------------|---------|----------|---------|---------|---------------------------------------- File | % Stmts | % Branch | % Funcs | % Lines | Uncovered Line #s ------------|---------|----------|---------|---------|---------------------------------------- All files | 33.87 | 87.5 | 0 | 33.87 | md2html.js | 33.87 | 87.5 | 0 | 33.87 | ...169,172-255,257-272,274-293,296-490 ------------|---------|----------|---------|---------|---------------------------------------- ERROR: Coverage for lines (33.87%) does not meet global threshold (100%) ERROR: Coverage for functions (0%) does not meet global threshold (100%) ERROR: Coverage for branches (87.5%) does not meet global threshold (100%) ERROR: Coverage for statements (33.87%) does not meet global threshold (100%) handrews@ixat new-oas %build-src output
This was run at the last prompt of the previous session, I just split it for readability: