interplane.Get Omega
Read in your language

aien-sovereign-core-mv

AienOS host runtime: inference scheduling, paged KV state, the aien CLI and Spark verification tooling. Its inference engine is in alpha testing (DGX Spark GB10); Omega is the implementation destination.

Brought by drakestapleton

branch main Branches Tags History

aien-sovereign-core-mv / crates / aien-campaign-verifier / tests / independence.rs

42 lines · 1702 bytes Raw Blame History
1// SPDX-License-Identifier: Apache-2.0
2// Copyright 2026 Drake Stapleton (AIEN / aien-dev)
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8// http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15
16//! SPEC.md Section 7: the verifier must not depend on any crate under test.
17
18const FORBIDDEN_PREFIXES: [&str; 4] = ["aien-", "spark-", "cortex-", "rad-"];
19
20#[test]
21fn verifier_has_no_dependency_on_code_under_test() {
22 let manifest = std::fs::read_to_string(concat!(env!("CARGO_MANIFEST_DIR"), "/Cargo.toml"))
23 .expect("read Cargo.toml");
24 let value: toml::Value = toml::from_str(&manifest).expect("parse Cargo.toml");
25
26 for section in ["dependencies", "dev-dependencies", "build-dependencies"] {
27 let Some(deps) = value.get(section).and_then(|d| d.as_table()) else {
28 continue;
29 };
30 for (name, spec) in deps {
31 assert!(
32 !FORBIDDEN_PREFIXES.iter().any(|p| name.starts_with(p)),
33 "{name} is workspace code under test"
34 );
35 assert!(spec.get("path").is_none(), "{name} is a path dependency");
36 }
37 }
38 assert!(
39 value.get("target").is_none(),
40 "target-specific dependencies must be reviewed for independence"
41 );
42}