Skip to content

Commit df838e9

Browse files
ci: use os from matrix
1 parent ff14190 commit df838e9

File tree

2 files changed

+2
-9
lines changed

2 files changed

+2
-9
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ on:
88
jobs:
99
build:
1010
name: Build and Test
11-
runs-on: ubuntu-latest
11+
runs-on: ${{ matrix.os }}
1212
strategy:
1313
matrix:
1414
os:

tests/src/lib.rs

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -101,13 +101,6 @@ mod tests {
101101

102102
static BUILD: Once = Once::new();
103103

104-
#[cfg(target_os = "linux")]
105-
const EXTENSION: &str = "so";
106-
#[cfg(target_os = "macos")]
107-
const EXTENSION: &str = "dylib";
108-
#[cfg(target_os = "windows")]
109-
const EXTENSION: &str = "dll";
110-
111104
fn setup() {
112105
BUILD.call_once(|| {
113106
assert_eq!(
@@ -128,7 +121,7 @@ mod tests {
128121
Command::new("php")
129122
.arg(format!(
130123
"-dextension=../target/debug/libtests.{}",
131-
EXTENSION
124+
std::env::consts::DLL_EXTENSION
132125
))
133126
.arg(format!("integration/{}", file))
134127
.output()

0 commit comments

Comments
 (0)