| Commit message (Collapse) | Author | Age | Files | Lines |
| ... | |
| | | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
(Also, document that this static assertion is the reason why you are
seeing a confusing error message.)
|
| | | | | |
| | | | |
| | | | |
| | | | | |
This simplifies our logging a little, and implements part of
|
| | |/ / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The main contribution here is a set of convenience macros for
logging error `Report`s. Notably, this macros always logs
`Internal` and `BadAspiUsage` errors at `WARN`, unless they
are already at `ERROR` or more.
This is a little tricky because `tracing::event!()` requires
its Level argument to be a constant.
|
| |\ \ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
add_warning: Tolerate clippy::missing_panics_doc
Closes #950
See merge request tpo/core/arti!1380
|
| | | | | |
| | | | |
| | | | |
| | | | | |
These are no longer needed.
|
| | |/ / /
| | | |
| | | |
| | | | |
Closes #950.
|
| |\ \ \ \
| |/ / /
|/| | |
| | | |
| | | |
| | | |
| | | | |
Fix various warnings from clippy nightly
Closes #943
See merge request tpo/core/arti!1369
|
| | | | |
| | | |
| | | |
| | | | |
This appeases clippy-nightly.
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Clippy nightly doesn't like `#[cfg(all(...))]` with only a single
expression inside the `all(...)`.
This requires an adjustment in check_doc_features.
|
| | |/ /
| | |
| | |
| | | |
This is a new warning^Wsuggestion from clippy nightly.
|
| | | | |
|
| | | |
| | |
| | |
| | | |
These are always the same and probably always will be.
|
| |\ \ \
| | | |
| | | |
| | | |
| | | | |
Introduce a MockExecutor for fully-isolated test cases
See merge request tpo/core/arti!1375
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
As per
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1375#note_2919976
|
| | | | | |
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
Discussion:
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1375#note_2919928
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
Requested by:
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1375#note_2919926
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
This will hopefully mean anyone trying to use this will notice that
it's not implemented.
Prompted by:
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1375#note_2919925
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | | |
This seems to have been overlooked.
|
| | | | |
| | | |
| | | |
| | | | |
This isn't used any more.
|
| | | | |
| | | |
| | | |
| | | | |
Run rustfmt.
|
| | | | |
| | | |
| | | |
| | | | |
This abolishes a bodge sleep. It should make the tests deterministic.
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Drain a number of events, not just one. The stream might yield many
events, as explained in this new comment.
This fails every time with MockExecutor::try_test_with_various().
I think it might fail with the tokio exeuctor too, but evidently not
with high probability or we would have noticed.
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Now we can reliably wait precisely for the tasks to be all waiting.
This test case no longer involves any real executor.
|
| | | | |
| | | |
| | | |
| | | | |
In both fallible and infallible variants, for convenience.
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
We want MockNetProvider to be Default.
In this commit: impl Default for MockNetwork and use it in new().
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
Pick an arbitrary start time roughly now. This will do for many
tests.
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Nothing in our tree actually *uses* the UDP in tests.
We want a mock UDP provider that isn't part of a real runtime, so that
we can make a totally-mock runtime for properly controlled testing.
It seems best to make this part of MockNetProvider rather than a
separate type.
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | | |
This deduplicates some imports, which would otherwise be about to
become triplicated.
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
This deduplicates some trait delegation.
We want this now because we're about to introduce a third mock
runtime, so this would become triplication otherwise.
|
| |\ \ \ \
| |/ / /
|/| | |
| | | |
| | | |
| | | |
| | | | |
arti: Add a `logging.time_granularity` option with 1s default.
Closes #551
See merge request tpo/core/arti!1376
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
I was unable to assure myself that tracing_subscriber could
withstand a panicking Timer, so instead I'm trying to make sure
our own LogTimer can't panic.
|
| | | |/
| |/|
| | |
| | |
| | |
| | |
| | | |
This lets us provide less information in our logs: in particular, it
lets us avoid logging with microsecond precision.
Closes #551.
|
| |\ \ \
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
arti: Install a panic hook that sends messages to `tracing`
Closes #921
See merge request tpo/core/arti!1377
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
The original version of our panic handler would allocate a string
for the panic `Location`. But if we're panicking we'd like to keep
allocations to a minimum: so instead format the `Location`
conditionally.
This also drops a useless `std::borrow::Cow`. (The possibility of a
"Don't have a `Cow`" commit message was considered and rejected.)
|
| | | | | |
|
| | | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
(Also leaves installed the default handler that sends messages to
stderr.)
Closes #921.
|
| |/ / / |
|