Skip to content

Commit fd5aed7

Browse files
authored
fix: use new api for loginstate in test
Fix test that crashed the CI, it used old LoginState
1 parent e0fcccb commit fd5aed7

1 file changed

Lines changed: 9 additions & 6 deletions

File tree

src/projects/create.rs

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -177,13 +177,16 @@ mod tests {
177177
create_behavior,
178178
});
179179
let server = MockServer::start(state).await;
180+
let login = LoginState::new();
181+
login.set(
182+
"test-key".to_string(),
183+
"org-1".to_string(),
184+
"test-org".to_string(),
185+
server.base_url.clone(),
186+
"https://app.example.com".to_string(),
187+
);
180188
let client = ApiClient::new(&LoginContext {
181-
login: LoginState {
182-
api_key: "test-key".to_string(),
183-
org_id: "org-1".to_string(),
184-
org_name: "test-org".to_string(),
185-
api_url: Some(server.base_url.clone()),
186-
},
189+
login,
187190
api_url: server.base_url.clone(),
188191
app_url: "https://app.example.com".to_string(),
189192
})

0 commit comments

Comments
 (0)