cbc46ad8eb
- clean up dead code - fix lints - move Session type to legacy module - refactor service names into constants - refactor build_url to be less restrictive for service names - refactor most commands into their own modules
18 lines
512 B
Rust
18 lines
512 B
Rust
include!(concat!(env!("OUT_DIR"), "/protobufs/mod.rs"));
|
|
|
|
#[cfg(test)]
|
|
mod parse_tests {
|
|
use protobuf::Message;
|
|
|
|
use super::steammessages_auth_steamclient::CAuthentication_GetPasswordRSAPublicKey_Request;
|
|
|
|
#[test]
|
|
fn test_build_protobuf() {
|
|
let mut req = CAuthentication_GetPasswordRSAPublicKey_Request::new();
|
|
req.set_account_name("hydrastar2".to_owned());
|
|
|
|
let bytes = req.write_to_bytes().unwrap();
|
|
let s = base64::encode_config(bytes, base64::URL_SAFE);
|
|
assert_eq!(s, "CgpoeWRyYXN0YXIy");
|
|
}
|
|
}
|