mirror of
				https://github.com/meilisearch/meilisearch.git
				synced 2025-11-04 01:46:28 +00:00 
			
		
		
		
	Use ubuntu-18.04 container in rust tests
This commit is contained in:
		
							
								
								
									
										12
									
								
								.github/workflows/flaky.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										12
									
								
								.github/workflows/flaky.yml
									
									
									
									
										vendored
									
									
								
							@@ -6,10 +6,20 @@ on:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
jobs:
 | 
					jobs:
 | 
				
			||||||
  flaky:
 | 
					  flaky:
 | 
				
			||||||
    runs-on: ubuntu-18.04
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					    container:
 | 
				
			||||||
 | 
					      image: ubuntu:18.04
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
    - uses: actions/checkout@v3
 | 
					    - uses: actions/checkout@v3
 | 
				
			||||||
 | 
					    - name: Install needed dependencies
 | 
				
			||||||
 | 
					      run: |
 | 
				
			||||||
 | 
					        apt-get update && apt-get install -y curl
 | 
				
			||||||
 | 
					        apt-get install build-essential -y
 | 
				
			||||||
 | 
					    - uses: actions-rs/toolchain@v1
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        toolchain: stable
 | 
				
			||||||
 | 
					        override: true
 | 
				
			||||||
    - name: Install cargo-flaky
 | 
					    - name: Install cargo-flaky
 | 
				
			||||||
      run: cargo install cargo-flaky
 | 
					      run: cargo install cargo-flaky
 | 
				
			||||||
    - name: Run cargo flaky 100 times
 | 
					    - name: Run cargo flaky 100 times
 | 
				
			||||||
 
 | 
				
			|||||||
							
								
								
									
										45
									
								
								.github/workflows/rust.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										45
									
								
								.github/workflows/rust.yml
									
									
									
									
										vendored
									
									
								
							@@ -15,13 +15,41 @@ env:
 | 
				
			|||||||
  RUSTFLAGS: "-D warnings"
 | 
					  RUSTFLAGS: "-D warnings"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
jobs:
 | 
					jobs:
 | 
				
			||||||
  tests:
 | 
					  test-linux:
 | 
				
			||||||
 | 
					    name: Tests on ubuntu-18.04
 | 
				
			||||||
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					    container:
 | 
				
			||||||
 | 
					      image: ubuntu:18.04
 | 
				
			||||||
 | 
					    steps:
 | 
				
			||||||
 | 
					    - uses: actions/checkout@v3
 | 
				
			||||||
 | 
					    - name: Install rustup
 | 
				
			||||||
 | 
					      run: |
 | 
				
			||||||
 | 
					        apt-get update && apt-get install -y curl
 | 
				
			||||||
 | 
					        apt-get install build-essential -y
 | 
				
			||||||
 | 
					    - uses: actions-rs/toolchain@v1
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        toolchain: stable
 | 
				
			||||||
 | 
					        override: true
 | 
				
			||||||
 | 
					    - name: Cache dependencies
 | 
				
			||||||
 | 
					      uses: Swatinem/rust-cache@v2.2.0
 | 
				
			||||||
 | 
					    - name: Run cargo check without any default features
 | 
				
			||||||
 | 
					      uses: actions-rs/cargo@v1
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        command: build
 | 
				
			||||||
 | 
					        args: --locked --release --no-default-features
 | 
				
			||||||
 | 
					    - name: Run cargo test
 | 
				
			||||||
 | 
					      uses: actions-rs/cargo@v1
 | 
				
			||||||
 | 
					      with:
 | 
				
			||||||
 | 
					        command: test
 | 
				
			||||||
 | 
					        args: --locked --release
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  test-others:
 | 
				
			||||||
    name: Tests on ${{ matrix.os }}
 | 
					    name: Tests on ${{ matrix.os }}
 | 
				
			||||||
    runs-on: ${{ matrix.os }}
 | 
					    runs-on: ${{ matrix.os }}
 | 
				
			||||||
    strategy:
 | 
					    strategy:
 | 
				
			||||||
      fail-fast: false
 | 
					      fail-fast: false
 | 
				
			||||||
      matrix:
 | 
					      matrix:
 | 
				
			||||||
        os: [ubuntu-18.04, macos-latest, windows-latest]
 | 
					        os: [macos-latest, windows-latest]
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
    - uses: actions/checkout@v3
 | 
					    - uses: actions/checkout@v3
 | 
				
			||||||
    - name: Cache dependencies
 | 
					    - name: Cache dependencies
 | 
				
			||||||
@@ -40,12 +68,17 @@ jobs:
 | 
				
			|||||||
  # We run tests in debug also, to make sure that the debug_assertions are hit
 | 
					  # We run tests in debug also, to make sure that the debug_assertions are hit
 | 
				
			||||||
  test-debug:
 | 
					  test-debug:
 | 
				
			||||||
    name: Run tests in debug
 | 
					    name: Run tests in debug
 | 
				
			||||||
    runs-on: ubuntu-18.04
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
 | 
					    container:
 | 
				
			||||||
 | 
					      image: ubuntu:18.04
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
      - uses: actions/checkout@v3
 | 
					      - uses: actions/checkout@v3
 | 
				
			||||||
 | 
					      - name: Install rustup
 | 
				
			||||||
 | 
					        run: |
 | 
				
			||||||
 | 
					          apt-get update && apt-get install -y curl
 | 
				
			||||||
 | 
					          apt-get install build-essential -y
 | 
				
			||||||
      - uses: actions-rs/toolchain@v1
 | 
					      - uses: actions-rs/toolchain@v1
 | 
				
			||||||
        with:
 | 
					        with:
 | 
				
			||||||
          profile: minimal
 | 
					 | 
				
			||||||
          toolchain: stable
 | 
					          toolchain: stable
 | 
				
			||||||
          override: true
 | 
					          override: true
 | 
				
			||||||
      - name: Cache dependencies
 | 
					      - name: Cache dependencies
 | 
				
			||||||
@@ -58,7 +91,7 @@ jobs:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  clippy:
 | 
					  clippy:
 | 
				
			||||||
    name: Run Clippy
 | 
					    name: Run Clippy
 | 
				
			||||||
    runs-on: ubuntu-18.04
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
      - uses: actions/checkout@v3
 | 
					      - uses: actions/checkout@v3
 | 
				
			||||||
      - uses: actions-rs/toolchain@v1
 | 
					      - uses: actions-rs/toolchain@v1
 | 
				
			||||||
@@ -77,7 +110,7 @@ jobs:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  fmt:
 | 
					  fmt:
 | 
				
			||||||
    name: Run Rustfmt
 | 
					    name: Run Rustfmt
 | 
				
			||||||
    runs-on: ubuntu-18.04
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
      - uses: actions/checkout@v3
 | 
					      - uses: actions/checkout@v3
 | 
				
			||||||
      - uses: actions-rs/toolchain@v1
 | 
					      - uses: actions-rs/toolchain@v1
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -16,7 +16,7 @@ jobs:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  update-version-cargo-toml:
 | 
					  update-version-cargo-toml:
 | 
				
			||||||
    name: Update version in Cargo.toml files
 | 
					    name: Update version in Cargo.toml files
 | 
				
			||||||
    runs-on: ubuntu-18.04
 | 
					    runs-on: ubuntu-latest
 | 
				
			||||||
    steps:
 | 
					    steps:
 | 
				
			||||||
      - uses: actions/checkout@v3
 | 
					      - uses: actions/checkout@v3
 | 
				
			||||||
      - uses: actions-rs/toolchain@v1
 | 
					      - uses: actions-rs/toolchain@v1
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user