MCPcopy Create free account
hub / github.com/alignoth/alignoth / test_plot_cigar_match

Function test_plot_cigar_match

src/plot.rs:915–938  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

913
914 #[test]
915 fn test_plot_cigar_match() {
916 let cigar_string = CigarStringView::new(CigarString::from(vec![Cigar::Match(10)]), 0);
917 let reference = vec!['A', 'A', 'G', 'C', 'T', 'A', 'T', 'A', 'T', 'A'];
918 let read = vec!['A', 'A', 'G', 'C', 'C', 'A', 'T', 'A', 'T', 'A'];
919 let cigar = PlotCigar::from_cigar(cigar_string, read, reference).unwrap();
920 let expected_cigar = PlotCigar(vec![
921 InnerPlotCigar {
922 cigar_type: CigarType::Match,
923 bases: None,
924 length: Some(4),
925 },
926 InnerPlotCigar {
927 cigar_type: CigarType::Sub,
928 bases: Some(vec!['C']),
929 length: Some(1),
930 },
931 InnerPlotCigar {
932 cigar_type: CigarType::Match,
933 bases: None,
934 length: Some(5),
935 },
936 ]);
937 assert_eq!(cigar, expected_cigar);
938 }
939
940 #[test]
941 fn test_plot_cigar_insertion() {

Callers

nothing calls this directly

Calls 1

PlotCigarClass · 0.85

Tested by

no test coverage detected