Skip to content

Commit 06a16bd

Browse files
committed
---
yaml --- r: 60223 b: refs/heads/master c: 9ed9e8c h: refs/heads/master i: 60221: b6e7773 60219: 50a9660 60215: 73a7033 60207: bfca8ad 60191: a0ffdd9 60159: f9d5afa v: v3
1 parent 8c7a091 commit 06a16bd

File tree

2 files changed

+15
-1
lines changed

2 files changed

+15
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: e2c73ccaf22ec3908cf77e604233c5833ac5ae7d
2+
refs/heads/master: 9ed9e8c8d0ff0502697e715c2cd0cedd3323d423
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: 2d28d645422c1617be58c8ca7ad9a457264ca850
55
refs/heads/try: c50a9d5b664478e533ba1d1d353213d70c8ad589

trunk/src/libcore/to_str.rs

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,4 +209,18 @@ mod tests {
209209
assert!(table_str == ~"{1: 2, 3: 4}" || table_str == ~"{3: 4, 1: 2}");
210210
assert!(empty.to_str() == ~"{}");
211211
}
212+
213+
#[test]
214+
fn test_hashset() {
215+
let mut set: HashSet<int, int> = HashSet::new();
216+
let empty_set: HashSet<int, int> = HashSet::new();
217+
218+
set.insert(1);
219+
set.insert(2);
220+
221+
let set_str = set.to_str();
222+
223+
assert!(set_str == ~"{1, 2}" || set_str == ~"{2, 1}");
224+
assert!(empty.to_str() == ~"{}");
225+
}
212226
}

0 commit comments

Comments
 (0)