File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed
Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -32,4 +32,16 @@ final class SKKServDictTests: XCTestCase {
3232 let dict = SKKServDict ( destination: destination, service: service, saveToUserDict: false )
3333 XCTAssertEqual ( dict. refer ( " へんかん " , option: nil ) . map { $0. word } , [ ] )
3434 }
35+
36+ func testFindCompletion( ) async throws {
37+ let service = MockedSKKServService ( response: " 1/ほかん/ほかく/ " )
38+ let dict = SKKServDict ( destination: destination, service: service, saveToUserDict: false )
39+ XCTAssertEqual ( dict. findCompletions ( prefix: " ほか " ) , [ " ほかん " , " ほかく " ] )
40+ }
41+
42+ func testFindCompletionNotFound( ) async throws {
43+ let service = MockedSKKServService ( response: " 4ほかん " )
44+ let dict = SKKServDict ( destination: destination, service: service, saveToUserDict: false )
45+ XCTAssertEqual ( dict. findCompletions ( prefix: " ほかん " ) , [ ] )
46+ }
3547}
You can’t perform that action at this time.
0 commit comments