Fix when calling parse_hex_char out of bounds
Closes: #158 Changelog-Fixed: Fix crash with @ sign in some posts
This commit is contained in:
committed by
William Casarin
parent
0af8646fd5
commit
205774f684
@@ -53,6 +53,14 @@ class ReplyTests: XCTestCase {
|
||||
XCTAssertEqual(blocks[0].is_text, content)
|
||||
}
|
||||
|
||||
func testAtAtEnd() {
|
||||
let content = "what @"
|
||||
let blocks = parse_post_blocks(content: content)
|
||||
|
||||
XCTAssertEqual(blocks.count, 1)
|
||||
XCTAssertEqual(blocks[0].is_text, "what @")
|
||||
}
|
||||
|
||||
func testHashtagsInQuote() {
|
||||
let content = "This is my \"#awesome post\""
|
||||
let blocks = parse_post_blocks(content: content)
|
||||
|
||||
Reference in New Issue
Block a user