mirror of
https://github.com/pcvolkmer/osc-variant.git
synced 2025-10-29 07:52:15 +00:00
refactor: replace match with let Some()
This commit is contained in:
@@ -802,9 +802,8 @@ mod tests {
|
|||||||
|
|
||||||
onkostar_editor.apply_profile(&profile);
|
onkostar_editor.apply_profile(&profile);
|
||||||
|
|
||||||
let actual = match &onkostar_editor.editor.data_form[0].entries {
|
let Some(actual) = &onkostar_editor.editor.data_form[0].entries else {
|
||||||
Some(entries) => entries,
|
panic!()
|
||||||
None => panic!(),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
@@ -838,9 +837,8 @@ mod tests {
|
|||||||
|
|
||||||
onkostar_editor.apply_profile(&profile);
|
onkostar_editor.apply_profile(&profile);
|
||||||
|
|
||||||
let actual = match &onkostar_editor.editor.data_form[0].entries {
|
let Some(actual) = &onkostar_editor.editor.data_form[0].entries else {
|
||||||
Some(entries) => entries,
|
panic!()
|
||||||
None => panic!(),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
@@ -875,9 +873,8 @@ mod tests {
|
|||||||
|
|
||||||
onkostar_editor.apply_profile(&profile);
|
onkostar_editor.apply_profile(&profile);
|
||||||
|
|
||||||
let actual = match &onkostar_editor.editor.data_form[0].entries {
|
let Some(actual) = &onkostar_editor.editor.data_form[0].entries else {
|
||||||
Some(entries) => entries,
|
panic!()
|
||||||
None => panic!(),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
assert_eq!(actual.entry[0].filter, None);
|
assert_eq!(actual.entry[0].filter, None);
|
||||||
@@ -912,9 +909,8 @@ mod tests {
|
|||||||
|
|
||||||
onkostar_editor.apply_profile(&profile);
|
onkostar_editor.apply_profile(&profile);
|
||||||
|
|
||||||
let actual = match &onkostar_editor.editor.data_form[0].entries {
|
let Some(actual) = &onkostar_editor.editor.data_form[0].entries else {
|
||||||
Some(entries) => entries,
|
panic!()
|
||||||
None => panic!(),
|
|
||||||
};
|
};
|
||||||
|
|
||||||
assert_eq!(actual.entry[0].filter, None);
|
assert_eq!(actual.entry[0].filter, None);
|
||||||
|
|||||||
Reference in New Issue
Block a user