Skip to content

Commit

Permalink
does even pass?
Browse files Browse the repository at this point in the history
  • Loading branch information
raphamorim committed Dec 21, 2024
1 parent 4558fb0 commit fe9f01d
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
39 changes: 20 additions & 19 deletions frontends/rioterm/src/context/grid.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1000,25 +1000,26 @@ pub mod test {
rich_text_id,
context_dimension,
);
// let context_width = context.dimension.width;
// let context_height = context.dimension.height;
// let context_margin = context.dimension.margin;
// let grid = ContextGrid::<VoidListener>::new(context, margin, [0., 0., 0., 0.]);
// // The first context should fill completely w/h grid
// assert_eq!(grid.width, context_width);
// assert_eq!(grid.height, context_height);

// // Context margin should empty
// assert_eq!(Delta::<f32>::default(), context_margin);
// assert_eq!(grid.margin, margin);

// assert_eq!(
// grid.objects(),
// vec![Object::RichText(RichText {
// id: rich_text_id,
// position: [10., 20.],
// })]
// );
panic!("does even pass?");
let context_width = context.dimension.width;
let context_height = context.dimension.height;
let context_margin = context.dimension.margin;
let grid = ContextGrid::<VoidListener>::new(context, margin, [0., 0., 0., 0.]);
// The first context should fill completely w/h grid
assert_eq!(grid.width, context_width);
assert_eq!(grid.height, context_height);

// Context margin should empty
assert_eq!(Delta::<f32>::default(), context_margin);
assert_eq!(grid.margin, margin);

assert_eq!(
grid.objects(),
vec![Object::RichText(RichText {
id: rich_text_id,
position: [10., 20.],
})]
);
}

// #[test]
Expand Down
1 change: 0 additions & 1 deletion frontends/rioterm/src/context/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,6 @@ pub fn create_mock_context<T: rio_backend::event::EventListener>(
let (sender, _receiver) = corcovado::channel::channel();
let messenger = Messenger::new(sender);
let renderable_content = RenderableContent::new(Cursor::default());
panic!("aaaa");

Context {
route_id,
Expand Down

0 comments on commit fe9f01d

Please sign in to comment.