ci(github): add Windows testing using Actions
This commit is contained in:
		
							parent
							
								
									1ffceaf580
								
							
						
					
					
						commit
						1eca9c7551
					
				
							
								
								
									
										39
									
								
								.github/workflows/kitchen.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							
							
						
						
									
										39
									
								
								.github/workflows/kitchen.yml
									
									
									
									
										vendored
									
									
										Normal file
									
								
							| @ -0,0 +1,39 @@ | ||||
| --- | ||||
| name: CI | ||||
| 
 | ||||
| 'on': [push, pull_request] | ||||
| 
 | ||||
| env: | ||||
|   machine_user: kitchen | ||||
|   machine_pass: Pass@word1 | ||||
|   machine_port: 5985 | ||||
|   KITCHEN_LOCAL_YAML: kitchen.github.yml | ||||
| 
 | ||||
| jobs: | ||||
|   build: | ||||
|     runs-on: windows-latest | ||||
| 
 | ||||
|     steps: | ||||
|       - uses: actions/checkout@v2 | ||||
|       - uses: actions/cache@v1 | ||||
|         with: | ||||
|           path: vendor/bundle | ||||
|           key: ${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }} | ||||
|           restore-keys: | | ||||
|             ${{ runner.os }}-gems- | ||||
|       - shell: powershell | ||||
|         run: | | ||||
|           $password = ConvertTo-SecureString $env:machine_pass -AsPlainText -Force | ||||
|           New-LocalUser $env:machine_user -Password $password | ||||
|           Add-LocalGroupMember -Group "Administrators" -Member $env:machine_user | ||||
|       - shell: powershell | ||||
|         run: > | ||||
|           Set-WSManQuickConfig -Force; | ||||
|           Set-WSManInstance -ResourceURI winrm/config/service | ||||
|           -ValueSet @{AllowUnencrypted="true"} | ||||
|       - run: gem install bundler --quiet --no-document | ||||
|       - name: Bundle install | ||||
|         run: | | ||||
|           bundle config path vendor/bundle | ||||
|           bundle install --jobs 4 --retry 3 | ||||
|       - run: bundle exec kitchen test | ||||
							
								
								
									
										40
									
								
								kitchen.github.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										40
									
								
								kitchen.github.yml
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,40 @@ | ||||
| --- | ||||
| driver: | ||||
|   name: proxy | ||||
|   host: localhost | ||||
|   reset_command: "exit 0" | ||||
|   port: 5985 | ||||
|   username: kitchen | ||||
|   password: Pass@word1 | ||||
| 
 | ||||
| platforms: | ||||
|   - name: windows | ||||
| 
 | ||||
| provisioner: | ||||
|   salt_install: bootstrap | ||||
|   salt_bootstrap_options: -pythonVersion 3 -version 3000.3 | ||||
|   init_environment: > | ||||
|     C:\salt\salt-call --local state.single file.managed | ||||
|     C:\Users\kitchen\AppData\Local\Temp\kitchen\srv\salt\win\repo-ng\salt-minion-py3.sls | ||||
|     source=https://github.com/saltstack/salt-winrepo-ng/raw/master/salt-minion-py3.sls | ||||
|     skip_verify=True makedirs=True | ||||
| 
 | ||||
| suites: | ||||
|   - name: v3000-py3 | ||||
|     provisioner: | ||||
|       state_top: | ||||
|         base: | ||||
|           '*': | ||||
|             - salt.minion | ||||
|       pillars: | ||||
|         top.sls: | ||||
|           base: | ||||
|             '*': | ||||
|               - salt | ||||
|               - v3000-py3 | ||||
|       pillars_from_files: | ||||
|         salt.sls: test/salt/pillar/salt.sls | ||||
|         v3000-py3.sls: test/salt/pillar/v3000-py3.sls | ||||
|     verifier: | ||||
|       inspec_tests: | ||||
|         - path: test/integration/v3000-py3 | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Dafydd Jones
						Dafydd Jones