mirror of
https://github.com/pbakaus/impeccable.git
synced 2026-09-13 22:56:33 +03:00
Compare commits
3
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b4dfde469c | ||
|
|
6099995338 | ||
|
|
45ad3c49e5 |
@@ -28,7 +28,7 @@ jobs:
|
||||
- { os: windows-latest, target: x86_64-pc-windows-msvc, short: windows-x64 }
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0
|
||||
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
|
||||
- name: Check the tag matches ENGINE_VERSION
|
||||
shell: bash
|
||||
run: |
|
||||
@@ -51,7 +51,7 @@ jobs:
|
||||
if: ${{ !matrix.cross }}
|
||||
shell: bash
|
||||
run: target/${{ matrix.target }}/release/impeccable${{ runner.os == 'Windows' && '.exe' || '' }} engine-probe
|
||||
- uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
||||
- uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
|
||||
with:
|
||||
name: impeccable-${{ matrix.short }}
|
||||
path: target/${{ matrix.target }}/release/impeccable${{ runner.os == 'Windows' && '.exe' || '' }}
|
||||
@@ -60,7 +60,7 @@ jobs:
|
||||
needs: build
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
|
||||
- uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
|
||||
with: { path: artifacts }
|
||||
- name: Lay out release assets with checksums
|
||||
run: |
|
||||
|
||||
@@ -687,11 +687,17 @@ mod tests_660 {
|
||||
use std::collections::HashMap;
|
||||
use std::path::PathBuf;
|
||||
|
||||
static TMP_SEQ: std::sync::atomic::AtomicUsize = std::sync::atomic::AtomicUsize::new(0);
|
||||
|
||||
fn tmp() -> String {
|
||||
let base = std::env::temp_dir().join(format!(
|
||||
"impeccable-critique-{}-{}",
|
||||
"impeccable-critique-{}-{}-{}",
|
||||
std::process::id(),
|
||||
std::time::SystemTime::now().duration_since(std::time::UNIX_EPOCH).unwrap().as_nanos()
|
||||
std::time::SystemTime::now().duration_since(std::time::UNIX_EPOCH).unwrap().as_nanos(),
|
||||
// A per-process counter: Windows' clock is coarse enough that two
|
||||
// parallel tests can share a nanosecond stamp and then delete each
|
||||
// other's directories.
|
||||
TMP_SEQ.fetch_add(1, std::sync::atomic::Ordering::Relaxed)
|
||||
));
|
||||
std::fs::create_dir_all(&base).unwrap();
|
||||
// Like Node's `realpathSync`: no `\\?\` verbatim prefix on Windows,
|
||||
|
||||
@@ -437,11 +437,17 @@ pub fn load_known_rule_ids() -> Option<Vec<String>> {
|
||||
mod tests {
|
||||
use super::check_hook_installation;
|
||||
|
||||
static TMP_SEQ: std::sync::atomic::AtomicUsize = std::sync::atomic::AtomicUsize::new(0);
|
||||
|
||||
fn tmp() -> String {
|
||||
let base = std::env::temp_dir().join(format!(
|
||||
"impeccable-doctor-hook-{}-{}",
|
||||
"impeccable-doctor-hook-{}-{}-{}",
|
||||
std::process::id(),
|
||||
std::time::SystemTime::now().duration_since(std::time::UNIX_EPOCH).unwrap().as_nanos()
|
||||
std::time::SystemTime::now().duration_since(std::time::UNIX_EPOCH).unwrap().as_nanos(),
|
||||
// A per-process counter: Windows' clock is coarse enough that two
|
||||
// parallel tests can share a nanosecond stamp and then delete each
|
||||
// other's directories.
|
||||
TMP_SEQ.fetch_add(1, std::sync::atomic::Ordering::Relaxed)
|
||||
));
|
||||
std::fs::create_dir_all(&base).unwrap();
|
||||
// Like Node's `realpathSync`: on Windows, `canonicalize` yields a
|
||||
|
||||
@@ -13,6 +13,8 @@ use impeccable_hook::hook_lib::{get_cache_path, get_pending_path, Runtime};
|
||||
use impeccable_hook::hook;
|
||||
use serde_json::json;
|
||||
|
||||
static TMP_SEQ: std::sync::atomic::AtomicUsize = std::sync::atomic::AtomicUsize::new(0);
|
||||
|
||||
static HTML: MissingHtmlEngine = MissingHtmlEngine;
|
||||
static ENV_LOCK: Mutex<()> = Mutex::new(());
|
||||
|
||||
@@ -47,9 +49,13 @@ struct Tmp(PathBuf);
|
||||
impl Tmp {
|
||||
fn new() -> Tmp {
|
||||
let base = std::env::temp_dir().join(format!(
|
||||
"impeccable-cache-root-{}-{}",
|
||||
"impeccable-cache-root-{}-{}-{}",
|
||||
std::process::id(),
|
||||
std::time::SystemTime::now().duration_since(std::time::UNIX_EPOCH).unwrap().as_nanos()
|
||||
std::time::SystemTime::now().duration_since(std::time::UNIX_EPOCH).unwrap().as_nanos(),
|
||||
// A per-process counter: Windows' clock is coarse enough that two
|
||||
// parallel tests can share a nanosecond stamp and then delete each
|
||||
// other's directories.
|
||||
TMP_SEQ.fetch_add(1, std::sync::atomic::Ordering::Relaxed)
|
||||
));
|
||||
std::fs::create_dir_all(&base).unwrap();
|
||||
// Like Node's `realpathSync`: no `\\?\` verbatim prefix on Windows, so the
|
||||
|
||||
Reference in New Issue
Block a user