mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-24 17:28:40 +00:00
Fix some tests
This commit is contained in:
parent
2456c077f6
commit
3412becfc5
2 changed files with 10 additions and 9 deletions
|
@ -18,12 +18,12 @@ fn test_update_channels(cx: &mut AppContext) {
|
|||
proto::Channel {
|
||||
id: 1,
|
||||
name: "b".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
},
|
||||
proto::Channel {
|
||||
id: 2,
|
||||
name: "a".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
},
|
||||
],
|
||||
channel_permissions: vec![proto::ChannelPermission {
|
||||
|
@ -51,12 +51,12 @@ fn test_update_channels(cx: &mut AppContext) {
|
|||
proto::Channel {
|
||||
id: 3,
|
||||
name: "x".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
},
|
||||
proto::Channel {
|
||||
id: 4,
|
||||
name: "y".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
},
|
||||
],
|
||||
insert_edge: vec![
|
||||
|
@ -96,17 +96,17 @@ fn test_dangling_channel_paths(cx: &mut AppContext) {
|
|||
proto::Channel {
|
||||
id: 0,
|
||||
name: "a".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
},
|
||||
proto::Channel {
|
||||
id: 1,
|
||||
name: "b".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
},
|
||||
proto::Channel {
|
||||
id: 2,
|
||||
name: "c".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
},
|
||||
],
|
||||
insert_edge: vec![
|
||||
|
@ -165,7 +165,7 @@ async fn test_channel_messages(cx: &mut TestAppContext) {
|
|||
channels: vec![proto::Channel {
|
||||
id: channel_id,
|
||||
name: "the-channel".to_string(),
|
||||
visibility: proto::ChannelVisibility::ChannelMembers as i32,
|
||||
visibility: proto::ChannelVisibility::Members as i32,
|
||||
}],
|
||||
..Default::default()
|
||||
});
|
||||
|
|
|
@ -143,7 +143,8 @@ impl Database {
|
|||
channel_id: ActiveValue::Set(channel_id_to_join),
|
||||
user_id: ActiveValue::Set(user_id),
|
||||
accepted: ActiveValue::Set(true),
|
||||
role: ActiveValue::Set(ChannelRole::Guest),
|
||||
// TODO: change this back to Guest.
|
||||
role: ActiveValue::Set(ChannelRole::Member),
|
||||
})
|
||||
.exec(&*tx)
|
||||
.await?;
|
||||
|
|
Loading…
Reference in a new issue