You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+13-2Lines changed: 13 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -39,9 +39,18 @@ There are several ways to contribute to posixutils-rs:
39
39
Code should be readable by unfamiliar developers. Avoid dense,
40
40
uncommented code.
41
41
42
-
### Testing, POSIX compliance and programmaticgoals
42
+
### Testing, POSIX compliance and programmatic goals
43
43
44
44
* All utilities should have tests.
45
+
* Use plib's TestPlan framework for integration tests.
46
+
* Test pattern:
47
+
1. Pre-generate input data files.
48
+
2. Run system OS utility on input data files,
49
+
generating known-good output.
50
+
3. Store input and output in-tree, as known-good data.
51
+
4. Write a TestPlan that executes our utility, using
52
+
static input data, and compares output with
53
+
static output data.
45
54
* Only "quick" tests should be run automatically in `cargo test`
46
55
* Longer tests, or tests requiring root access, should be triggered
47
56
via special environment variables.
@@ -50,7 +59,9 @@ There are several ways to contribute to posixutils-rs:
50
59
* If a system has an OS-specific feature that _must_ be
51
60
exposed through a given utility, do so.
52
61
* Race-free userland. See `ftw` internal crate.
53
-
* Push small crates out: Create tiny, light-dep crates from common functionality (such as Lex or Yacc file parsing), and publish via cargo. Remove from main posixutils tree and set of crates.
62
+
* Push small crates out: Create tiny, light-dep crates from common
63
+
functionality (such as Lex or Yacc file parsing), and publish via cargo.
64
+
Remove from main posixutils tree and set of crates.
54
65
55
66
### Testing and Bug Reporting: Info to provide in GH issue
0 commit comments