about summary refs log tree commit diff
path: root/src/libextra/test.rs
AgeCommit message (Collapse)AuthorLines
2014-02-20move extra::test to libtestLiigo Zhuang-1553/+0
2014-02-19librustc: Remove unique vector patterns from the language.Patrick Walton-5/+8
Preparatory work for removing unique vectors from the language, which is itself preparatory work for dynamically sized types.
2014-02-19Fix typo in test metric ratchet stdout outputMatthijs van der Vleuten-1/+1
2014-02-18auto merge of #12345 : huonw/rust/speeling, r=cmrbors-1/+1
2014-02-18Spellcheck library docs.Huon Wilson-1/+1
2014-02-16Update clients of the TaskBuilder APIKevin Ballard-5/+4
2014-02-14extern mod => extern crateAlex Crichton-2/+2
This was previously implemented, and it just needed a snapshot to go through
2014-02-14extra: Capture stdout/stderr of tests by defaultAlex Crichton-33/+52
When tests fail, their stdout and stderr is printed as part of the summary, but this helps suppress failure messages from #[should_fail] tests and generally clean up the output of the test runner.
2014-02-13Removed num::OrderableMichael Darakananda-4/+6
2014-02-11Rewrite channels yet again for upgradeabilityAlex Crichton-7/+7
This, the Nth rewrite of channels, is not a rewrite of the core logic behind channels, but rather their API usage. In the past, we had the distinction between oneshot, stream, and shared channels, but the most recent rewrite dropped oneshots in favor of streams and shared channels. This distinction of stream vs shared has shown that it's not quite what we'd like either, and this moves the `std::comm` module in the direction of "one channel to rule them all". There now remains only one Chan and one Port. This new channel is actually a hybrid oneshot/stream/shared channel under the hood in order to optimize for the use cases in question. Additionally, this also reduces the cognitive burden of having to choose between a Chan or a SharedChan in an API. My simple benchmarks show no reduction in efficiency over the existing channels today, and a 3x improvement in the oneshot case. I sadly don't have a pre-last-rewrite compiler to test out the old old oneshots, but I would imagine that the performance is comparable, but slightly slower (due to atomic reference counting). This commit also brings the bonus bugfix to channels that the pending queue of messages are all dropped when a Port disappears rather then when both the Port and the Chan disappear.
2014-02-08auto merge of #12105 : huonw/rust/bench-black-box, r=alexcrichtonbors-2/+14
This allows a result to be marked as "used" by passing it to a function LLVM cannot see inside (unless LTO is enabled). Closes #8261.
2014-02-09extra::test: add an opaque function to assist with accurateHuon Wilson-2/+14
benchmarking. This allows a result to be marked as "used" by passing it to a function LLVM cannot see inside. By making `iter` generic and using this `black_box` on the result benchmarks can get this behaviour simply by returning their computation.
2014-02-07Delete send_str, rewrite clients on top of MaybeOwned<'static>Kevin Ballard-2/+2
Declare a `type SendStr = MaybeOwned<'static>` to ease readibility of types that needed the old SendStr behavior. Implement all the traits for MaybeOwned that SendStr used to implement.
2014-02-07moved collections from libextra into libcollectionsHeroesGrave-1/+1
2014-02-06getopts: unify testsArcterus-1/+1
2014-02-06getopts: replaced base functions with those from groupArcterus-13/+12
2014-02-06Move getopts out of extraArcterus-1/+1
2014-02-03extra: Fix tests with io_error usageAlex Crichton-2/+2
2014-02-03extra: Remove io_error usageAlex Crichton-92/+115
2014-02-02Move term, terminfo out of extra.xales-1/+1
cc #8784
2014-01-29Removing do keyword from libextraScott Lawrence-2/+2
2014-01-27Demote self to an (almost) regular argument and remove the env param.Eduard Burtescu-1/+1
Fixes #10667 and closes #10259.
2014-01-26std,extra: Make some types public and other private.Huon Wilson-2/+4
These are either returned from public functions, and really should appear in the documentation, but don't since they're private, or are implementation details that are currently public.
2014-01-21[std::str] Rename from_utf8_opt() to from_utf8(), drop the old from_utf8() ↵Simon Sapin-1/+1
behavior
2014-01-21[std::vec] Rename .pop_opt() to .pop(), drop the old .pop() behaviorSimon Sapin-1/+1
2014-01-17auto merge of #11598 : alexcrichton/rust/io-export, r=brsonbors-1/+1
* Reexport io::mem and io::buffered structs directly under io, make mem/buffered private modules * Remove with_mem_writer * Remove DEFAULT_CAPACITY and use DEFAULT_BUF_SIZE (in io::buffered) cc #11119
2014-01-17Tweak the interface of std::ioAlex Crichton-1/+1
* Reexport io::mem and io::buffered structs directly under io, make mem/buffered private modules * Remove with_mem_writer * Remove DEFAULT_CAPACITY and use DEFAULT_BUF_SIZE (in io::buffered)
2014-01-16Update test run summaryDerek Guenther-1/+1
2014-01-13Clean up std::num::cmath and remove stale commentsBrendan Zabarauskas-1/+1
2014-01-11Remove re-exports of std::io::stdio::{print, println} in the prelude.Brendan Zabarauskas-3/+3
The `print!` and `println!` macros are now the preferred method of printing, and so there is no reason to export the `stdio` functions in the prelude. The functions have also been replaced by their macro counterparts in the tutorial and other documentation so that newcomers don't get confused about what they should be using.
2014-01-08Remove the io::Decorator traitAlex Crichton-2/+1
This is just an unnecessary trait that no one's ever going to parameterize over and it's more useful to just define the methods directly on the types themselves. The implementors of this type almost always don't want inner_mut_ref() but they're forced to define it as well.
2014-01-06Remove some unnecessary type castsFlorian Hahn-4/+4
Conflicts: src/librustc/middle/lint.rs
2014-01-04Don't allow newtype structs to be dereferenced. #6246Brian Anderson-5/+15
2014-01-03libextra: Remove unnecessary `@mut`sPatrick Walton-1/+2
2014-01-03Remove std::eitherAlex Crichton-10/+15
2013-12-22std::vec: make the sorting closure use `Ordering` rather than just beingHuon Wilson-4/+1
(implicitly) less_eq.
2013-12-21std::vec: add a sugary .sort() method for plain Ord sorting.Huon Wilson-3/+2
This moves the custom sorting to `.sort_by`.
2013-12-20extra: remove sort in favour of the std method.Huon Wilson-4/+3
Fixes #9676.
2013-12-17Don't allow impls to force public typesAlex Crichton-3/+1
This code in resolve accidentally forced all types with an impl to become public. This fixes it by default inheriting the privacy of what was previously there and then becoming `true` if nothing else exits. Closes #10545
2013-12-16Fallout of rewriting std::commAlex Crichton-13/+6
2013-12-13extra::test: handle slow benchmarks more gracefully.Huon Wilson-1/+10
This makes sure we always run benchmarks even if they are predicted to take a long time, so that we have some non-zero time to display (although the error bars may be huge for particularly slow benchmarks). Fixes #9532.
2013-12-10libextra: Another round of de-`Cell`-ing.Patrick Walton-2/+1
34 uses of `Cell` remain.
2013-12-04Rename extra::json::*::init() constructors to *::new()Kevin Ballard-1/+1
2013-12-04Revert "libstd: Change `Path::new` to `Path::init`."Kevin Ballard-3/+3
This reverts commit c54427ddfbbab41a39d14f2b1dc4f080cbc2d41b. Leave the #[ignores] in that were added to rustpkg tests. Conflicts: src/librustc/driver/driver.rs src/librustc/metadata/creader.rs
2013-11-30auto merge of #10727 : erickt/rust/json, r=huonwbors-2/+3
This PR does some small modernizations to the json library. First is to remove the `@` boxes, second is to rename the constructors to `new`.
2013-11-29extra: missed a couple `@` in jsonErick Tryzelaar-2/+3
2013-11-29extra: Rename json constructors into *::initErick Tryzelaar-1/+1
2013-11-29libstd: Change `Path::new` to `Path::init`.Patrick Walton-3/+3
2013-11-28Register new snapshotsAlex Crichton-6/+6
2013-11-26librustc: Make `||` lambdas not infer to `proc`sPatrick Walton-7/+7