Sha256: 137aa627239fa304e6874181b9a81c3d194acbf459fe3edd009a5c45038ed1d5
Contents?: true
Size: 937 Bytes
Versions: 29
Compression:
Stored size: 937 Bytes
Contents
extern crate hamming; #[test] fn test_no_difference_between_empty_strands() { assert_eq!(hamming::hamming_distance("", ""), Some(0)); } #[test] #[ignore] fn test_no_difference_between_identical_strands() { assert_eq!(hamming::hamming_distance("GGACTGA", "GGACTGA"), Some(0)); } #[test] #[ignore] fn test_complete_hamming_distance_in_small_strand() { assert_eq!(hamming::hamming_distance("ACT", "GGA"), Some(3)); } #[test] #[ignore] fn test_small_hamming_distance_in_the_middle_somewhere() { assert_eq!(hamming::hamming_distance("GGACG", "GGTCG"), Some(1)); } #[test] #[ignore] fn test_larger_distance() { assert_eq!(hamming::hamming_distance("ACCAGGG", "ACTATGG"), Some(2)); } #[test] #[ignore] fn test_first_string_is_longer() { assert_eq!(hamming::hamming_distance("AAA", "AA"), None); } #[test] #[ignore] fn test_second_string_is_longer() { assert_eq!(hamming::hamming_distance("A", "AA"), None); }
Version data entries
29 entries across 29 versions & 1 rubygems