letexpected="<SwipePage active_page:0 page_count:1 content:<Paragraphs This is the first paragraph\nand it should fit on the\nscreen entirely.\nSecond, bold, paragraph\nshould also fit on the\nscreen whole I think.\n> buttons:<Empty > >";
letexpected="<SwipePage active_page::0,page_count::1,content:<Paragraphs **CONTENT** This is the first paragraph\nand it should fit on the\nscreen entirely.\nSecond, bold, paragraph\nshould also fit on the\nscreen whole I think.\n **CONTENT** > buttons:<Empty > >";
assert_eq!(trace(&page),expected);
swipe_up(&mutpage);
@ -497,8 +497,8 @@ mod tests {
);
page.place(SCREEN);
letexpected1="<SwipePage active_page:0 page_count:2 content:<Paragraphs This is somewhat long\nparagraph that goes on\nand on and on and on\nand on and will definitely\nnot fit on just a single\nscreen. You have to\nswipe a bit to see all the\ntext it contains I guess....\n> buttons:<FixedHeightBar inner:<Button text:NO > > >";
letexpected2="<SwipePage active_page:1 page_count:2 content:<Paragraphs There's just so much\nletters in it.\n> buttons:<FixedHeightBar inner:<Button text:NO > > >";
letexpected1="<SwipePage active_page::0,page_count::2,content:<Paragraphs **CONTENT** This is somewhat long\nparagraph that goes on\nand on and on and on\nand on and will definitely\nnot fit on just a single\nscreen. You have to\nswipe a bit to see all the\ntext it contains I guess....\n **CONTENT** > buttons:<FixedHeightBar inner:<Button text:NO > > >";
letexpected2="<SwipePage active_page::1,page_count::2,content:<Paragraphs **CONTENT** There's just so much\nletters in it.\n **CONTENT** > buttons:<FixedHeightBar inner:<Button text:NO > > >";
assert_eq!(trace(&page),expected1);
swipe_down(&mutpage);
@ -533,9 +533,9 @@ mod tests {
);
page.place(SCREEN);
letexpected1="<SwipePage active_page:0 page_count:3 content:<Paragraphs This paragraph is using a\nbold font. It doesn't\nneed to be all that long.\nAnd this one is\nusing MONO. Mono\nspace is nice fo\nr numbers, they\n> buttons:<FixedHeightBar inner:<Button text:IDK > > >";
letexpected2="<SwipePage active_page:1 page_count:3 content:<Paragraphs have the same wi\ndth and can be s\ncanned quickly.\nEven if they spa\nn several pages\nor something.\nLet's add another one...\n> buttons:<FixedHeightBar inner:<Button text:IDK > > >";
letexpected3="<SwipePage active_page:2 page_count:3 content:<Paragraphs for a good measure. This\none should overflow all\nthe way to the third\npage with a bit of luck.\n> buttons:<FixedHeightBar inner:<Button text:IDK > > >";
letexpected1="<SwipePage active_page::0,page_count::3,content:<Paragraphs **CONTENT** This paragraph is using a\nbold font. It doesn't\nneed to be all that long.\nAnd this one is\nusing MONO. Mono\nspace is nice fo\nr numbers, they\n **CONTENT** > buttons:<FixedHeightBar inner:<Button text:IDK > > >";
letexpected2="<SwipePage active_page::1,page_count::3,content:<Paragraphs **CONTENT** have the same wi\ndth and can be s\ncanned quickly.\nEven if they spa\nn several pages\nor something.\nLet's add another one...\n **CONTENT** > buttons:<FixedHeightBar inner:<Button text:IDK > > >";
letexpected3="<SwipePage active_page::2,page_count::3,content:<Paragraphs **CONTENT** for a good measure. This\none should overflow all\nthe way to the third\npage with a bit of luck.\n **CONTENT** > buttons:<FixedHeightBar inner:<Button text:IDK > > >";