solution to exercise 04_03

This commit is contained in:
David Doblas Jiménez 2024-07-01 16:30:43 +02:00
parent 0829174983
commit 604a5a20ae

View File

@ -8,7 +8,13 @@ struct Ticket {
// TODO: Implement the `PartialEq` trait for `Ticket`.
impl PartialEq for Ticket {}
impl PartialEq for Ticket {
fn eq(&self, other: &Self) -> bool {
self.title == other.title
&& self.description == other.description
&& self.status == other.status
}
}
#[cfg(test)]
mod tests {