36 lines
		
	
	
		
			714 B
		
	
	
	
		
			YAML
		
	
	
	
	
	
			
		
		
	
	
			36 lines
		
	
	
		
			714 B
		
	
	
	
		
			YAML
		
	
	
	
	
	
name: test
 | 
						|
 | 
						|
on:
 | 
						|
  push:
 | 
						|
    branches: [ main ]
 | 
						|
 | 
						|
env:
 | 
						|
  CARGO_TERM_COLOR: always
 | 
						|
 | 
						|
jobs:
 | 
						|
  tests:
 | 
						|
    name: AoC 2024
 | 
						|
    runs-on: ubuntu-latest
 | 
						|
    steps:
 | 
						|
    - uses: actions/checkout@v3
 | 
						|
    - name: setup toolchain
 | 
						|
      uses: actions-rust-lang/setup-rust-toolchain@v1
 | 
						|
      with:
 | 
						|
        cache: true
 | 
						|
        components: clippy, rustfmt
 | 
						|
        toolchain: stable
 | 
						|
 | 
						|
    - name: fake inputs
 | 
						|
      run: |
 | 
						|
        mkdir -p input/2024/
 | 
						|
        for i in $(seq 1 25); do touch input/2024/day${i}.txt; done
 | 
						|
 | 
						|
    - name: cargo test
 | 
						|
      run: cargo test --lib --all-features
 | 
						|
 | 
						|
    - name: rustfmt
 | 
						|
      run: cargo fmt --all -- --check
 | 
						|
 | 
						|
    # - name: clippy
 | 
						|
    #   run: cargo clippy --lib --all-features --tests -- -D warnings
 |