Start work on displaying channels and invites in collab panel

This commit is contained in:
Max Brunsfeld 2023-07-31 18:00:14 -07:00
parent 003a711dea
commit 7954b02819
8 changed files with 412 additions and 70 deletions

View file

@ -193,6 +193,7 @@ impl TestServer {
let app_state = Arc::new(workspace::AppState {
client: client.clone(),
user_store: user_store.clone(),
channel_store: channel_store.clone(),
languages: Arc::new(LanguageRegistry::test()),
fs: fs.clone(),
build_window_options: |_, _, _| Default::default(),

View file

@ -29,11 +29,12 @@ async fn test_basic_channels(
client_a.channel_store.read_with(cx_a, |channels, _| {
assert_eq!(
channels.channels(),
&[Channel {
&[Arc::new(Channel {
id: channel_a_id,
name: "channel-a".to_string(),
parent_id: None,
}]
depth: 0,
})]
)
});
@ -56,11 +57,12 @@ async fn test_basic_channels(
client_b.channel_store.read_with(cx_b, |channels, _| {
assert_eq!(
channels.channel_invitations(),
&[Channel {
&[Arc::new(Channel {
id: channel_a_id,
name: "channel-a".to_string(),
parent_id: None,
}]
depth: 0,
})]
)
});
@ -76,11 +78,12 @@ async fn test_basic_channels(
assert_eq!(channels.channel_invitations(), &[]);
assert_eq!(
channels.channels(),
&[Channel {
&[Arc::new(Channel {
id: channel_a_id,
name: "channel-a".to_string(),
parent_id: None,
}]
depth: 0,
})]
)
});
}