Commit Graph

14 Commits

Author SHA1 Message Date
Lewin Bormann
e0f3298904 test(ServiceAccount): Add test with internal mockito web server. 2019-06-21 11:22:24 +02:00
Lewin Bormann
18411a0610 imp(Storage): Implement Default for MemoryStorage and make errors sendable 2019-06-13 15:30:50 +02:00
Lewin Bormann
59b2b03b7d rewrite(serviceaccount): Rewrite ServiceAccountAccess to use futures.
Also add example/test to check if obtaining tokens using JWTs works.
2019-06-12 13:50:56 +02:00
Lewin Bormann
ce9b6d8dd7 chore(syntax): Remove extern crate imports where not needed 2019-06-09 09:24:15 +02:00
Lyle Mantooth
108162fcf8 imp: accept any string-like parameter
Use the power of the `AsRef` trait to take generic parameters for
several API functions. This makes the API more ergonomic because the
callers may pass in static `str` slices or references to owned `String`s
or even more exotic things like a `Cow`, all based on their particular
situation.

Update the tests and examples to use the most natural types they have
available.

Fixes #77. No existing code should break, as `&String` implements
`AsRef<str>` and `AsRef<Path>`
2019-04-03 09:01:28 -04:00
Guy Taylor
b96cfcd66a Format to fustfmt defaults and force lint check in Travis 2019-02-21 20:46:00 +00:00
Jamie Turner
ab4b2c2fd4 Rust 2018 edition modifications. 2019-01-04 12:43:19 -08:00
Lewin Bormann
d4ebbc47b2 chore(language): Sort imports and migrate from deprecated types.
std:#️⃣:SipHasher is not std::collections::hash_map::DefaultHasher
(really!?).
Imports were unordered.
2017-01-31 19:27:50 +01:00
Lewin Bormann
0506ffaa44 feat(helpers): Implement hash_scope() helper function 2016-09-20 20:19:00 +02:00
Lewin Bormann
85b12dd3e8 refactor(common): Rename common -> types 2016-08-31 20:01:24 +02:00
Lewin Bormann
9e59bf0496 refactor(all): More flows demand for a different structure
I mainly resolved some circular dependencies that had crept in, and
moved code around. I renamed helper.rs because that was not really an
appropriate name anymore, and moved the delegate code into a new module.
2016-08-31 19:48:38 +02:00
Sebastian Thiel
22bb255a55 fix(dependencies): work with latest dependencies on nightly
Stable doesn't quite work yet due to the cargo issue further
described [here][cargo-issue]

[cargo-issue]: https://github.com/rust-lang/cargo/issues/2064
2016-05-20 08:57:06 +02:00
Lewin Bormann
ae5e94bf7b fix(DiskTokenStorage): make DiskTokenStorage::new() return a Result<> 2016-04-25 19:14:53 +02:00
Lewin Bormann
2cb5250e72 feat(storage): Implement DiskTokenStorage
DiskTokenStorage is a TokenStorage that stores its tokens in a JSON file
on disk. That file can be read in later, and the tokens in it reused.
(The idea for a cache file is from here:
https://developers.google.com/drive/v3/web/quickstart/go)
2016-04-15 19:42:50 +00:00