mirror of
https://github.com/sigoden/dufs.git
synced 2026-04-09 00:59:02 +03:00
feat: deprecate --auth-method, as both options are available (#279)
* feat: deprecate `--auth-method`, both are avaiable * send one www-authenticate with two schemes
This commit is contained in:
@@ -12,7 +12,7 @@ use std::process::{Command, Stdio};
|
||||
|
||||
#[rstest]
|
||||
#[case(&["-a", "user:pass@/:rw", "--log-format", "$remote_user"], false)]
|
||||
#[case(&["-a", "user:pass@/:rw", "--log-format", "$remote_user", "--auth-method", "basic"], true)]
|
||||
#[case(&["-a", "user:pass@/:rw", "--log-format", "$remote_user"], true)]
|
||||
fn log_remote_user(
|
||||
tmpdir: TempDir,
|
||||
port: u16,
|
||||
@@ -41,7 +41,7 @@ fn log_remote_user(
|
||||
|
||||
assert_eq!(resp.status(), 200);
|
||||
|
||||
let mut buf = [0; 2000];
|
||||
let mut buf = [0; 4096];
|
||||
let buf_len = stdout.read(&mut buf)?;
|
||||
let output = std::str::from_utf8(&buf[0..buf_len])?;
|
||||
|
||||
@@ -69,7 +69,7 @@ fn no_log(tmpdir: TempDir, port: u16, #[case] args: &[&str]) -> Result<(), Error
|
||||
let resp = fetch!(b"GET", &format!("http://localhost:{port}")).send()?;
|
||||
assert_eq!(resp.status(), 200);
|
||||
|
||||
let mut buf = [0; 1000];
|
||||
let mut buf = [0; 4096];
|
||||
let buf_len = stdout.read(&mut buf)?;
|
||||
let output = std::str::from_utf8(&buf[0..buf_len])?;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user