From b19f873f1359c3fde5f1040d38fa37c9bca92490 Mon Sep 17 00:00:00 2001 From: Martin Geisler Date: Fri, 14 Jul 2023 12:09:46 +0200 Subject: [PATCH] ko: refresh translation for testing (#931) * ko: refresh translation for testing Part of #925. * Apply suggestions from code review Co-authored-by: Jiyong Park <55639800+jiyongp@users.noreply.github.com> --------- Co-authored-by: Jiyong Park <55639800+jiyongp@users.noreply.github.com> --- po/ko.po | 91 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) diff --git a/po/ko.po b/po/ko.po index f6e4266d4ab3..81b6ef742a5a 100644 --- a/po/ko.po +++ b/po/ko.po @@ -9854,6 +9854,77 @@ msgstr "" msgid "Use `cargo test` to find and run the unit tests." msgstr "`cargo test` 커맨드를 사용하면 단위 테스트를 찾아서 실행합니다." +#: src/testing/unit-tests.md:5 +msgid "" +"```rust,editable,ignore\n" +"fn first_word(text: &str) -> &str {\n" +" match text.find(' ') {\n" +" Some(idx) => &text[..idx],\n" +" None => &text,\n" +" }\n" +"}\n" +"\n" +"#[test]\n" +"fn test_empty() {\n" +" assert_eq!(first_word(\"\"), \"\");\n" +"}\n" +"\n" +"#[test]\n" +"fn test_single_word() {\n" +" assert_eq!(first_word(\"Hello\"), \"Hello\");\n" +"}\n" +"\n" +"#[test]\n" +"fn test_multiple_words() {\n" +" assert_eq!(first_word(\"Hello World\"), \"Hello\");\n" +"}\n" +"```" +msgstr "" +"```rust,editable,ignore\n" +"fn first_word(text: &str) -> &str {\n" +" match text.find(' ') {\n" +" Some(idx) => &text[..idx],\n" +" None => &text,\n" +" }\n" +"}\n" +"\n" +"#[test]\n" +"fn test_empty() {\n" +" assert_eq!(first_word(\"\"), \"\");\n" +"}\n" +"\n" +"#[test]\n" +"fn test_single_word() {\n" +" assert_eq!(first_word(\"Hello\"), \"Hello\");\n" +"}\n" +"\n" +"#[test]\n" +"fn test_multiple_words() {\n" +" assert_eq!(first_word(\"Hello World\"), \"Hello\");\n" +"}\n" +"```" + +#: src/testing/useful-crates.md:1 +msgid "## Useful crates for writing tests" +msgstr "## 테스트 작성에 유용한 크레이트" + +#: src/testing/useful-crates.md:5 +msgid "Here are some additional crates which we recommend for writing tests:" +msgstr "다음은 테스트를 작성할 때 권장되는 추가 크레이트입니다." + +#: src/testing/useful-crates.md:7 +msgid "" +"* [googletest](https://docs.rs/googletest): Comprehensive test assertion " +"library in the tradition of GoogleTest for C++.\n" +"* [proptest](https://docs.rs/proptest): Property-based testing for Rust.\n" +"* [rstest](https://docs.rs/rstest): Support for fixtures and parameterised " +"tests." +msgstr "" +"* [googletest](https://docs.rs/googletest): C++용 GoogleTest의 방식을 따르는 테스트 라이브러리 입니다.\n" +"* [proptest](https://docs.rs/proptest): Rust용 속성 기반 테스트입니다.\n" +"* [rstest](https://docs.rs/rstest): 픽스처 및 매개변수화된 테스트를 지원합니" +"다." + #: src/testing/test-modules.md:1 msgid "# Test Modules" msgstr "# 테스트 모듈" @@ -9886,6 +9957,25 @@ msgid "" "}\n" "```" msgstr "" +"```rust,editable\n" +"fn helper(a: &str, b: &str) -> String {\n" +" format!(\"{a} {b}\")\n" +"}\n" +"\n" +"pub fn main() {\n" +" println!(\"{}\", helper(\"Hello\", \"World\"));\n" +"}\n" +"\n" +"#[cfg(test)]\n" +"mod tests {\n" +" use super::*;\n" +"\n" +" #[test]\n" +" fn test_helper() {\n" +" assert_eq!(helper(\"foo\", \"bar\"), \"foo bar\");\n" +" }\n" +"}\n" +"```" #: src/testing/test-modules.md:26 msgid "" @@ -13981,6 +14071,7 @@ msgid "" "```" msgstr "" + #: src/basic-syntax/scalar-types.md:21 msgid "There are a few syntaxes which are not shown above:" msgstr "위에 표시되지 않은 몇 가지 문법이 있습니다."