Skip to content

Commit 152bd20

Browse files
committed
Fix tests
1 parent 63e78e3 commit 152bd20

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

Core/Tests/PromptToCodeServiceTests/ExtractCodeFromChatGPTTests.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import XCTest
33

44
final class ExtractCodeFromChatGPTTests: XCTestCase {
55
func test_extract_from_no_code_block() {
6-
let api = OpenAIPromptToCodeService()
6+
let api = SimpleModificationAgent()
77
let result = api.extractCodeAndDescription(from: """
88
hello world!
99
""")
@@ -13,7 +13,7 @@ final class ExtractCodeFromChatGPTTests: XCTestCase {
1313
}
1414

1515
func test_extract_from_incomplete_code_block() {
16-
let api = OpenAIPromptToCodeService()
16+
let api = SimpleModificationAgent()
1717
let result = api.extractCodeAndDescription(from: """
1818
```swift
1919
func foo() {}
@@ -24,7 +24,7 @@ final class ExtractCodeFromChatGPTTests: XCTestCase {
2424
}
2525

2626
func test_extract_from_complete_code_block() {
27-
let api = OpenAIPromptToCodeService()
27+
let api = SimpleModificationAgent()
2828
let result = api.extractCodeAndDescription(from: """
2929
```swift
3030
func foo() {}
@@ -40,7 +40,7 @@ final class ExtractCodeFromChatGPTTests: XCTestCase {
4040
}
4141

4242
func test_extract_from_incomplete_code_block_without_language() {
43-
let api = OpenAIPromptToCodeService()
43+
let api = SimpleModificationAgent()
4444
let result = api.extractCodeAndDescription(from: """
4545
```
4646
func foo() {}
@@ -51,7 +51,7 @@ final class ExtractCodeFromChatGPTTests: XCTestCase {
5151
}
5252

5353
func test_extract_from_code_block_without_language() {
54-
let api = OpenAIPromptToCodeService()
54+
let api = SimpleModificationAgent()
5555
let result = api.extractCodeAndDescription(from: """
5656
```
5757
func foo() {}

Tool/Tests/LangChainTests/VectorStoreTests/TemporaryUSearchTests.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ class TemporaryUSearchTests: XCTestCase {
2626

2727
func test_setting_data() async throws {
2828
let identifier = "hello-world"
29-
let store = TemporaryUSearch(identifier: identifier)
29+
let store = TemporaryUSearch(identifier: identifier, dimensions: 4)
3030
try await store.set(EmbeddingData.data.map { datum in
3131
.init(
3232
document: .init(pageContent: datum.text, metadata: [:]),

0 commit comments

Comments
 (0)