Skip to content

Commit

Permalink
cleaner test harness, bump version for publish
Browse files Browse the repository at this point in the history
  • Loading branch information
nickbclifford committed Jan 14, 2024
1 parent 92e5dcc commit dcd36e3
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 14 deletions.
18 changes: 9 additions & 9 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "dotnetdll"
version = "0.0.1"
version = "0.0.2"
authors = ["Nick Clifford <nick@nickclifford.me>"]
edition = "2021"
license = "GPL-3.0+"
Expand All @@ -17,19 +17,19 @@ members = [
]

[dependencies]
bitfield = "0.14.0"
bitfield = "0.14"
bitvec = "1"
dotnetdll-macros = { path = "dotnetdll-macros", version = "0.0.1" }
num-traits = "0.2"
num-derive = "0.4"
object = { version = "0.32.1", features = ['write'] }
paste = "1.0.5"
scroll = { version = "0.11.0", features = ['derive'] }
scroll-buffer = "0.3.1"
thiserror = "1.0.31"
tracing = "0.1.40"
object = { version = "0.32", features = ['write'] }
paste = "1"
scroll = { version = "0.11", features = ['derive'] }
scroll-buffer = "0.3"
thiserror = "1"
tracing = "0.1"

[dev-dependencies]
once_cell = "1.16.0"
once_cell = "1"
regex = "1"
tempfile = "3"
11 changes: 6 additions & 5 deletions tests/common/mod.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#![allow(dead_code)]

use std::path::PathBuf;
use dotnetdll::prelude::*;
use std::process::Command;
use tempfile::TempDir;
Expand Down Expand Up @@ -151,17 +152,17 @@ pub fn write_fixture(
let stderr = String::from_utf8(output.stderr)?;

if stderr.contains("Unhandled exception") {
if env::optional("ILDASM").is_some() {
Command::new(env::ILDASM.clone()).arg(&dll_path).spawn()?.wait()?;
if let Some(path) = env::optional("ILDASM") {
Command::new(path).arg(&dll_path).spawn()?.wait()?;
}

if let Ok(r) = std::env::var("RUNTIME") {
if let Some(r) = env::optional("RUNTIME") {
Command::new("gdb")
.arg("-ex")
.arg(format!("set substitute-path /runtime {}", r))
.arg("--args")
.arg(if env::optional("ILDASM").is_some() {
env::ILDASM.clone()
.arg(if let Some(path) = env::optional("ILDASM"){
PathBuf::from(path)
} else {
env::LIBRARIES.join("corerun")
})
Expand Down

0 comments on commit dcd36e3

Please sign in to comment.