Skip to content

Commit

Permalink
langref: Explain Zig Test
Browse files Browse the repository at this point in the history
Updates the Language Reference sections: Comments, Values, and Zig Test.

Zig Test section moved down with the goal "make sure it can be read top to
bottom sensibly" in mind (issue ziglang#1524).

Comments and Values section examples changed test declarations to a main
function and expect statement to print statments.

A print statement was added to the "String Literals and Unicode Code Point"
section's example to demonstrate the "u" format specifier.

Zig Test Section:
* Addresses the question: "How does the syntax work?".
* Partially answers the question: "What can I do with the zig test tool?" but
should be sufficient to understand the examples in all of this document.
* Addresses the question: "How does a top-level test block differ from a function definition?"
* Provides a example to run multiple test.

Lacks clear definitions of containers, top-level, order independence, lazy
analysis, resolve, and reference.

GitHub Issues: ziglang#8221, ziglang#8234
  • Loading branch information
paulespinosa committed Sep 29, 2021
1 parent 99961f2 commit ac9ce64
Showing 1 changed file with 343 additions and 111 deletions.
Loading

0 comments on commit ac9ce64

Please sign in to comment.