- Add error handling for client initialization - Improve example scripts for clarity and robustness - Refine client configuration and usage patterns - Update documentation with current examples and features - Enhance model handling and response processing
14 lines
354 B
V
14 lines
354 B
V
module openrouter
|
|
|
|
fn test_factory() {
|
|
mut client := get(name: 'default', create: true)!
|
|
assert client.name == 'default'
|
|
assert client.url == 'https://openrouter.ai/api/v1'
|
|
assert client.model_default == 'qwen/qwen-2.5-coder-32b-instruct'
|
|
}
|
|
|
|
fn test_client_creation() {
|
|
mut client := new(name: 'test_client')!
|
|
assert client.name == 'test_client'
|
|
}
|