Skip to content

Commit

Permalink
Add CODEOWNERS file, audit-check workflow, and rename CI workflow
Browse files Browse the repository at this point in the history
- Added a new CODEOWNERS file to specify default owners for the repository.
- Added an audit-check workflow that runs security audits on files with Cargo.toml and Cargo.lock extensions.
- Renamed the rust.yml workflow to ci.yml to better reflect its purpose as a general CI workflow.
- Updated the ci.yml workflow to run on multiple operating systems (ubuntu-latest, macos-latest, windows-latest).
- Added "acgetchell" to the cspell.json dictionary.
- Added a test case for creating a Point in point.rs.
  • Loading branch information
acgetchell committed Dec 15, 2023
1 parent ebc1c61 commit 3ee6c99
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These owners will be the default owners for everything in the repo

* @acgetchell
14 changes: 14 additions & 0 deletions .github/workflows/audit-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
name: Security audit
on:
push:
paths:
- '**/Cargo.toml'
- '**/Cargo.lock'
jobs:
security_audit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions-rs/audit-check@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
12 changes: 10 additions & 2 deletions .github/workflows/rust.yml → .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Rust
name: CI

on:
push:
Expand All @@ -12,7 +12,15 @@ env:
jobs:
build:

runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}
strategy:
fail-fast: true

matrix:
os:
- ubuntu-latest
- macos-latest
- windows-latest

steps:
- uses: actions/checkout@v3
Expand Down
1 change: 1 addition & 0 deletions cspell.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"dictionaryDefinitions": [],
"dictionaries": [],
"words": [
"acgetchell",
"CGAL",
"Voronoi"
],
Expand Down
1 change: 1 addition & 0 deletions src/delaunay_core/cell.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ mod tests {
use crate::delaunay_core::point::Point;

use super::*;

#[test]
fn make_cell() {
let vertex1 = Vertex::new(Point::new(1.0, 2.0, 3.0), 3);
Expand Down
15 changes: 15 additions & 0 deletions src/delaunay_core/point.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,18 @@ impl<T> Point<T> {
Self { x, y, z }
}
}

#[cfg(test)]
mod tests {

use super::*;

#[test]
fn make_point() {
let point = Point::new(1.0, 2.0, 3.0);
println!("{:?}", point);
assert_eq!(point.x, 1.0);
assert_eq!(point.y, 2.0);
assert_eq!(point.z, 3.0);
}
}

0 comments on commit 3ee6c99

Please sign in to comment.