From: Mark Date: Mon, 3 Jul 2023 19:18:53 +0000 (-0600) Subject: update tests X-Git-Tag: v0.9.2~95^2 X-Git-Url: https://git.sagredo.dev/?a=commitdiff_plain;h=refs%2Fremotes%2Forigin%2Fiso-conformity-tests;p=scryer-prolog.git update tests --- diff --git a/src/heap_print.rs b/src/heap_print.rs index 4aef1ab1..4e7781b7 100644 --- a/src/heap_print.rs +++ b/src/heap_print.rs @@ -1657,6 +1657,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0) ); @@ -1686,6 +1687,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0) ); @@ -1710,6 +1712,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0) ); @@ -1723,6 +1726,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0) ); @@ -1754,6 +1758,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0), ); @@ -1773,6 +1778,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0), ); @@ -1790,6 +1796,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0) ); @@ -1820,6 +1827,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0) ); @@ -1843,6 +1851,7 @@ mod tests { &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), pstr_loc_as_cell!(0) ); @@ -1866,15 +1875,18 @@ mod tests { wam.machine_st.heap.push(empty_list_as_cell!()); { - let printer = HCPrinter::new( + let mut printer = HCPrinter::new( &mut wam.machine_st.heap, &mut wam.machine_st.atom_tbl, &mut wam.machine_st.stack, &wam.op_dir, + wam.machine_st.flags, PrinterOutputter::new(), heap_loc_as_cell!(0), ); + printer.double_quotes = true; + let output = printer.print(); assert_eq!(output.result(), "\"abcabc\""); @@ -1893,7 +1905,7 @@ mod tests { assert_eq!( &wam.parse_and_print_term("[a,b,\"a\",[a,b,c]].").unwrap(), - "[a,b,\"a\",\"abc\"]" + "[a,b,[a],[a,b,c]]" ); all_cells_unmarked(&wam.machine_st.heap); @@ -1901,7 +1913,7 @@ mod tests { assert_eq!( &wam.parse_and_print_term("[\"abc\",e,f,[g,e,h,Y,v|[X,Y]]].") .unwrap(), - "[\"abc\",e,f,[g,e,h,Y,v,X,Y]]" + "[[a,b,c],e,f,[g,e,h,Y,v,X,Y]]" ); all_cells_unmarked(&wam.machine_st.heap);