Skip to content

Commit

Permalink
document; add Chinese and Korean characters to tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jeremyandrews committed Nov 1, 2023
1 parent 9c44acf commit aee0175
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## 0.17.3-dev
- [#565](https://github.com/tag1consulting/goose/pull/565) add `--accept-invalid-certs` to skip validation of https certificates
- [#568](https://github.com/tag1consulting/goose/pull/568) don't panic when truncating non utf-8 string

## 0.17.2 August 28, 2023
- [#557](https://github.com/tag1consulting/goose/pull/557) speed up user initialization on Linux
Expand Down
7 changes: 7 additions & 0 deletions src/util.rs
Original file line number Diff line number Diff line change
Expand Up @@ -564,6 +564,13 @@ mod tests {
assert_eq!(truncate_string("abcde", 2), "..");
assert_eq!(truncate_string("これはテストだ", 10), "これはテストだ");
assert_eq!(truncate_string("これはテストだ", 3), "こ..");
assert_eq!(truncate_string("这是一个测试。", 10), "这是一个测试。");
assert_eq!(truncate_string("这是一个测试。", 3), "这..");
assert_eq!(
truncate_string("이것은 테스트입니다.", 15),
"이것은 테스트입니다."
);
assert_eq!(truncate_string("이것은 테스트입니다.", 3), "이..");
}

#[tokio::test]
Expand Down

0 comments on commit aee0175

Please sign in to comment.