| 841 | #[test] |
| 842 | #[ignore = "Requires environment configuration and is expensive"] |
| 843 | fn test_delete_file_ok() { |
| 844 | #[tokio::main] |
| 845 | async fn run(context: &mut TestContext) { |
| 846 | let username = context.do_login(1).await; |
| 847 | let (filename, content) = context.random_file(); |
| 848 | |
| 849 | context.service.patch_file_content(&username, &filename, content).await.unwrap(); |
| 850 | |
| 851 | context.service.delete_file(&username, &filename).await.unwrap(); |
| 852 | |
| 853 | let err = context.service.get_file(&username, &filename).await.unwrap_err(); |
| 854 | assert_eq!(io::ErrorKind::NotFound, err.kind(), "{}", err); |
| 855 | assert!(format!("{}", err).contains("(server code: 404")); |
| 856 | } |
| 857 | run(&mut TestContext::new_from_env()); |
| 858 | } |
| 859 | |
| 860 | #[test] |
| 861 | #[ignore = "Requires environment configuration and is expensive"] |