about summary refs log tree commit diff
path: root/src/doc/style/testing
diff options
context:
space:
mode:
authorSteve Klabnik <steve@steveklabnik.com>2016-07-29 18:56:09 -0400
committerSteve Klabnik <steve@steveklabnik.com>2016-08-25 15:22:12 -0400
commit00d4a43d84d5979332dbbbc4329211b007f7fe45 (patch)
treea14e37839ce0715c1eeb56b9b824bce15759e372 /src/doc/style/testing
parent528c6f3ed6a23a374dc5a40582d1bea2f2cfda65 (diff)
downloadrust-00d4a43d84d5979332dbbbc4329211b007f7fe45.tar.gz
rust-00d4a43d84d5979332dbbbc4329211b007f7fe45.zip
Remove style guide.
We originally imported this into the repository with the intent of
fixing it up. Instead, nothing happened.

Its appearance on rust-lang.org makes it seem semi-official, but it's
not. The rustfmt strike team will end up producing something like this
anyway, and leaving it around does nothing but mislead people.
Diffstat (limited to 'src/doc/style/testing')
-rw-r--r--src/doc/style/testing/README.md5
-rw-r--r--src/doc/style/testing/unit.md30
2 files changed, 0 insertions, 35 deletions
diff --git a/src/doc/style/testing/README.md b/src/doc/style/testing/README.md
deleted file mode 100644
index a21f69414d3..00000000000
--- a/src/doc/style/testing/README.md
+++ /dev/null
@@ -1,5 +0,0 @@
-% Testing
-
-> **[FIXME]** Add some general remarks about when and how to unit
-> test, versus other kinds of testing. What are our expectations for
-> Rust's core libraries?
diff --git a/src/doc/style/testing/unit.md b/src/doc/style/testing/unit.md
deleted file mode 100644
index dbbe9fc3ac6..00000000000
--- a/src/doc/style/testing/unit.md
+++ /dev/null
@@ -1,30 +0,0 @@
-% Unit testing
-
-Unit tests should live in a `tests` submodule at the bottom of the module they
-test. Mark the `tests` submodule with `#[cfg(test)]` so it is only compiled when
-testing.
-
-The `tests` module should contain:
-
-* Imports needed only for testing.
-* Functions marked with `#[test]` striving for full coverage of the parent module's
-  definitions.
-* Auxiliary functions needed for writing the tests.
-
-For example:
-
-``` rust
-// Excerpt from std::str
-
-#[cfg(test)]
-mod tests {
-    #[test]
-    fn test_eq() {
-        assert!((eq(&"".to_owned(), &"".to_owned())));
-        assert!((eq(&"foo".to_owned(), &"foo".to_owned())));
-        assert!((!eq(&"foo".to_owned(), &"bar".to_owned())));
-    }
-}
-```
-
-> **[FIXME]** add details about useful macros for testing, e.g. `assert!`