Reflect changes to Channel::modify() in test
This commit is contained in:
parent
40edc2c7fe
commit
4b31fb4ec7
|
@ -31,6 +31,7 @@ async fn delete_channel() {
|
||||||
#[tokio::test]
|
#[tokio::test]
|
||||||
async fn modify_channel() {
|
async fn modify_channel() {
|
||||||
let mut bundle = common::setup().await;
|
let mut bundle = common::setup().await;
|
||||||
|
let channel = &mut bundle.channel;
|
||||||
let modify_data: types::ChannelModifySchema = types::ChannelModifySchema {
|
let modify_data: types::ChannelModifySchema = types::ChannelModifySchema {
|
||||||
name: Some("beepboop".to_string()),
|
name: Some("beepboop".to_string()),
|
||||||
channel_type: None,
|
channel_type: None,
|
||||||
|
@ -50,10 +51,10 @@ async fn modify_channel() {
|
||||||
default_thread_rate_limit_per_user: None,
|
default_thread_rate_limit_per_user: None,
|
||||||
video_quality_mode: None,
|
video_quality_mode: None,
|
||||||
};
|
};
|
||||||
let result = Channel::modify(modify_data, bundle.channel.id, &mut bundle.user)
|
Channel::modify(channel, modify_data, channel.id, &mut bundle.user)
|
||||||
.await
|
.await
|
||||||
.unwrap();
|
.unwrap();
|
||||||
assert_eq!(result.name, Some("beepboop".to_string()));
|
assert_eq!(channel.name, Some("beepboop".to_string()));
|
||||||
|
|
||||||
let permission_override = PermissionFlags::from_vec(Vec::from([
|
let permission_override = PermissionFlags::from_vec(Vec::from([
|
||||||
PermissionFlags::MANAGE_CHANNELS,
|
PermissionFlags::MANAGE_CHANNELS,
|
||||||
|
|
Loading…
Reference in New Issue