Browse Source

Basic attempt at documentation

Luiserebii 1 year ago
parent
commit
6e916278be
Signed by: Luiserebii <luis@serebii.io> GPG Key ID: 525A84BC981B7D3E
2 changed files with 21 additions and 1 deletions
  1. 1
    1
      README.md
  2. 20
    0
      docs/README.md

+ 1
- 1
README.md View File

@@ -75,7 +75,7 @@ string.h
75 75
 ```
76 76
 
77 77
 ## Testing
78
-Run `make && ./a.out` in the `test/` directory to test, which will run through functions and produce reasonable output.
78
+Run `make && ./a.out` in the [`test/`](test) directory to test, which will run through functions and produce reasonable output.
79 79
 
80 80
 ## License
81 81
 This code has been licensed under the GNU General Public License v3.0.

+ 20
- 0
docs/README.md View File

@@ -1,2 +1,22 @@
1 1
 # Mintx86asm32 API
2 2
 
3
+This section contains documentation on using the Mint test framework. Each function is documented with its prototype and a brief description. Similar functions will be grouped together and described for brevity.
4
+
5
+Running an assertion function causes a line to print to the standard output stream describing the success or failure of the assertion.
6
+
7
+## Testing Boolean Value
8
+
9
+The functions below assert a particular boolean value, which parallels the way expressions are evaluated and determine the behavior of control structures in C (i.e. `true` as non-zero and `false` otherwise).
10
+
11
+### test\_assert(int32\_t cond, char\* title)
12
+
13
+Asserts `cond` as true. Alias of `test_assert_true()`.
14
+
15
+### test\_assert\_true(int32\_t cond, char\* title)
16
+
17
+Asserts `cond` as true.
18
+
19
+### test\_assert\_false(int32\_t cond, char\* title)
20
+
21
+Asserts `cond` as false.
22
+

Loading…
Cancel
Save