Skip to content

Commit 9fb0807

Browse files
authored
Merge pull request #145 from DeterminateSystems/fix-broken-test
Fix broken test
2 parents 9c9224a + bc88126 commit 9fb0807

File tree

6 files changed

+27
-34
lines changed

6 files changed

+27
-34
lines changed

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "flake-checker"
3-
version = "0.2.0"
3+
version = "0.2.1"
44
edition = "2021"
55

66
[workspace]

flake.lock

Lines changed: 19 additions & 25 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

flake.nix

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,10 @@
22
inputs = {
33
nixpkgs.url = "https://flakehub.com/f/NixOS/nixpkgs/0.2405.*";
44
rust-overlay = {
5-
url = "github:oxalica/rust-overlay";
6-
inputs.nixpkgs.follows = "nixpkgs";
7-
};
8-
crane = {
9-
url = "https://flakehub.com/f/ipetkov/crane/0.17.*";
5+
url = "https://flakehub.com/f/oxalica/rust-overlay/*";
106
inputs.nixpkgs.follows = "nixpkgs";
117
};
8+
crane.url = "https://flakehub.com/f/ipetkov/crane/0.19.*";
129
};
1310

1411
outputs = { self, ... }@inputs:

src/flake.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -157,7 +157,7 @@ mod test {
157157
fn cel_conditions() {
158158
// (condition, expected)
159159
let cases: Vec<(&str, bool)> = vec![
160-
(include_str!("../tests/cel-condition.txt"), true),
160+
(include_str!("../tests/cel-condition.cel"), true),
161161
(
162162

163163
"has(gitRef) && has(numDaysOld) && has(owner) && has(supportedRefs) && supportedRefs.contains(gitRef) && owner != 'NixOS'",
@@ -189,6 +189,8 @@ mod test {
189189
);
190190

191191
if expected {
192+
println!("{result:?}");
193+
192194
assert!(result.is_ok());
193195
assert!(result.unwrap().is_empty());
194196
} else {
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
supportedRefs == ['nixos-24.05', 'nixos-24.05-small', 'nixos-unstable', 'nixos-unstable-small', 'nixpkgs-24.05-darwin', 'nixpkgs-unstable']
1+
['nixos-unstable', 'nixos-unstable-small', 'nixpkgs-unstable'].map(rev, supportedRefs.contains(rev))
22
&& owner == 'NixOS'
33
&& gitRef == 'nixos-unstable'
44
&& supportedRefs.contains(gitRef)

0 commit comments

Comments
 (0)