Skip to content

Commit 88959a6

Browse files
committed
test: add PostgrestError LocalizedError conformance test
- Add test to verify PostgrestError properly conforms to LocalizedError protocol - Test ensures errorDescription property returns the expected error message - Improves test coverage for error handling functionality
1 parent be79f4d commit 88959a6

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
//
2+
// PostgrestErrorTests.swift
3+
// Supabase
4+
//
5+
// Created by Guilherme Souza on 07/05/24.
6+
//
7+
8+
import Foundation
9+
import Helpers
10+
import XCTest
11+
12+
final class PostgrestErrorTests: XCTestCase {
13+
14+
func testLocalizedErrorConformance() {
15+
let error = PostgrestError(message: "test error message")
16+
XCTAssertEqual(error.errorDescription, "test error message")
17+
}
18+
19+
}

0 commit comments

Comments
 (0)