feat: add channel search

This commit is contained in:
ThetaDev 2022-12-08 21:53:44 +01:00
parent 402f5834d2
commit 4c1876cb55
8 changed files with 151 additions and 171 deletions

View file

@ -948,6 +948,19 @@ async fn channel_info() {
"###);
}
#[tokio::test]
async fn channel_search() {
let rp = RustyPipe::builder().strict().build();
let channel = rp
.query()
.channel_search("UC2DjFE7Xf11URZqWBigcVOQ", "test")
.await
.unwrap();
assert_channel_eevblog(&channel);
assert_next(channel.content, rp.query(), 20, 2).await;
}
fn assert_channel_eevblog<T>(channel: &Channel<T>) {
assert_eq!(channel.id, "UC2DjFE7Xf11URZqWBigcVOQ");
assert_eq!(channel.name, "EEVblog");