38 lines
		
	
	
		
			854 B
		
	
	
	
		
			Groovy
		
	
	
	
	
	
			
		
		
	
	
			38 lines
		
	
	
		
			854 B
		
	
	
	
		
			Groovy
		
	
	
	
	
	
pipeline {
 | 
						|
    agent any
 | 
						|
 | 
						|
    stages {
 | 
						|
        stage('Checkout') {
 | 
						|
            steps {
 | 
						|
                git url: 'http://10.1.1.1:3000/hasslesstech/shmuliar-sp-kr-lab4.git'
 | 
						|
            }
 | 
						|
        }
 | 
						|
 | 
						|
        stage('Build') {
 | 
						|
            steps {
 | 
						|
                sh 'make -j$(nproc) build test'
 | 
						|
            }
 | 
						|
        }
 | 
						|
 | 
						|
        stage('Test') {
 | 
						|
            steps {
 | 
						|
                sh './tester test/testcases_sort_official'
 | 
						|
                sh './tester test/testcases_sort_custom'
 | 
						|
 | 
						|
                script {
 | 
						|
                    try {
 | 
						|
                        sh './tester test/testcases_sort_wrong'
 | 
						|
                        error("Wrong test indicates success!")
 | 
						|
                    } catch (Exception e) {}
 | 
						|
                }
 | 
						|
            }
 | 
						|
        }
 | 
						|
 | 
						|
        stage('Clean Up') {
 | 
						|
            steps {
 | 
						|
                sh 'make clean'
 | 
						|
            }
 | 
						|
        }
 | 
						|
    }
 | 
						|
}
 |