mirror of
				https://github.com/juanfont/headscale.git
				synced 2025-10-28 10:51:44 +01:00 
			
		
		
		
	Added makefile and .github
This commit is contained in:
		
							parent
							
								
									b0fda6b216
								
							
						
					
					
						commit
						89c468fc43
					
				
							
								
								
									
										35
									
								
								.github/workflows/test-integration-v2-general-auth.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										35
									
								
								.github/workflows/test-integration-v2-general-auth.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							@ -0,0 +1,35 @@
 | 
			
		||||
name: Integration Test v2
 | 
			
		||||
 | 
			
		||||
on: [pull_request]
 | 
			
		||||
 | 
			
		||||
jobs:
 | 
			
		||||
  integration-test-v2:
 | 
			
		||||
    runs-on: ubuntu-latest
 | 
			
		||||
 | 
			
		||||
    steps:
 | 
			
		||||
      - uses: actions/checkout@v2
 | 
			
		||||
        with:
 | 
			
		||||
          fetch-depth: 2
 | 
			
		||||
 | 
			
		||||
      - name: Set Swap Space
 | 
			
		||||
        uses: pierotofy/set-swap-space@master
 | 
			
		||||
        with:
 | 
			
		||||
          swap-size-gb: 10
 | 
			
		||||
 | 
			
		||||
      - name: Get changed files
 | 
			
		||||
        id: changed-files
 | 
			
		||||
        uses: tj-actions/changed-files@v14.1
 | 
			
		||||
        with:
 | 
			
		||||
          files: |
 | 
			
		||||
            *.nix
 | 
			
		||||
            go.*
 | 
			
		||||
            **/*.go
 | 
			
		||||
            integration_test/
 | 
			
		||||
            config-example.yaml
 | 
			
		||||
 | 
			
		||||
      - uses: cachix/install-nix-action@v16
 | 
			
		||||
        if: steps.changed-files.outputs.any_changed == 'true'
 | 
			
		||||
 | 
			
		||||
      - name: Run general integration tests
 | 
			
		||||
        if: steps.changed-files.outputs.any_changed == 'true'
 | 
			
		||||
        run: nix develop --command -- make test_integration_v2_auth_web_flow
 | 
			
		||||
							
								
								
									
										11
									
								
								Makefile
									
									
									
									
									
								
							
							
						
						
									
										11
									
								
								Makefile
									
									
									
									
									
								
							@ -68,6 +68,17 @@ test_integration_v2_general:
 | 
			
		||||
		golang:1 \
 | 
			
		||||
		go test $(TAGS) -failfast ./... -timeout 60m -parallel 6
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
test_integration_v2_auth_web_flow:
 | 
			
		||||
	docker run \
 | 
			
		||||
		-t --rm \
 | 
			
		||||
		-v ~/.cache/hs-integration-go:/go \
 | 
			
		||||
		--name headscale-test-suite \
 | 
			
		||||
		-v $$PWD:$$PWD -w $$PWD/integration \
 | 
			
		||||
		-v /var/run/docker.sock:/var/run/docker.sock \
 | 
			
		||||
		golang:1 \
 | 
			
		||||
		go test ./... -timeout 60m -parallel 6 -run TestAuthWebFlow
 | 
			
		||||
 | 
			
		||||
coverprofile_func:
 | 
			
		||||
	go tool cover -func=coverage.out
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user