temp test for windows

This commit is contained in:
Brandon Thomas committed 2025-03-02 20:31:34 -05:00
1 parent 360c3a268b
commit 202b7876b4
4 files changed
+20

No files matched your search

Generated
+1
View File
@@ -629,6 +629,7 @@ dependencies = [
"filesys",
"hf-hub 0.3.2",
"image",
"libloading 0.8.6",
"log",
"memory_caching",
"once_cell",
+3
View File
@@ -48,3 +48,6 @@ tokenizers = "0.15.2"
[features]
default = ["cuda"]
cuda = ["candle-core/cuda", "candle-nn/cuda", "candle-transformers/cuda"]
[dev-dependencies]
libloading = "0.8.6"
+9
View File
@@ -1,6 +1,15 @@
// Prevents additional console window on Windows in release, DO NOT REMOVE!!
#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]
use std::fs::File;
fn main() {
// NB: This is a test to see the behavior of the application with dynamic loading modules.
// We should be able to execute code before loading CUDA and other dependencies.
let r = File::create("program_started.txt");
match r {
Err(err) => println!("Failed to create program_started.txt: {}", err),
Ok(_) => {}
}
app_lib::run();
}
@@ -0,0 +1,7 @@
#[test]
fn test_dynamic_library_loading() {
let name = libloading::library_filename("cublas");
assert_eq!(name, "libcublas.so");
}