agave-jobs/jobs-core/src/test/java/org/iplantc/service/jobs/managers/JobRequestProcessorIT.java
/**
	 * Tests whether the JobManager.selectQueue method returns the expected queue
	 * given a set of inputs.
	 * 
	 * @param testQueues the queues to assign to the execution system for use in the test
	 * @param nodes the number of nodes to request
	 * @param memory the amount of memory to request
	 * @param requestedTime the amount of time to request
	 * @param expectedQueueName the name of the queue that should be selected
	 * @param message the assertion message to be returned if the test fails
	 */
Tests whether the JobManager.selectQueue method returns the expected queue
given a set of inputs.


Tests whether the JobManager . selectQueue method returns the expected queue given a set of inputs .
@Test(dataProvider = "selectQueueLimitTestProvider", dependsOnMethods = { "validateBatchSubmitParameters" })
	public void selectQueueLimitTest(BatchQueue[] testQueues, Long nodes, Double memory, String requestedTime, String expectedQueueName, String message) 
	{
		try 
		{
			ExecutionSystem testSystem = createExecutionSystem();
			testSystem.getBatchQueues().clear();
			for (BatchQueue testQueue: testQueues) {
				testSystem.addBatchQueue(testQueue);
			}
			BatchQueue selectedQueue = JobManager.selectQueue(testSystem, nodes, memory, requestedTime);
			String selectedQueueName = (selectedQueue == null ? null : selectedQueue.getName());
			assertEquals(selectedQueueName, expectedQueueName, message);
		} 
		catch (Exception e) {
			Assert.fail(message, e);
		}
	}
@ Test ( dataProvider = "selectQueueLimitTestProvider" , dependsOnMethods = { "validateBatchSubmitParameters" } ) public void selectQueueLimitTest ( BatchQueue [ ] testQueues , Long nodes , Double memory , String requestedTime , String expectedQueueName , String message ) { try { ExecutionSystem testSystem = createExecutionSystem ( ) ; testSystem . getBatchQueues ( ) . clear ( ) ; for ( BatchQueue testQueue : testQueues ) { testSystem . addBatchQueue ( testQueue ) ; } BatchQueue selectedQueue = JobManager . selectQueue ( testSystem , nodes , memory , requestedTime ) ; String selectedQueueName = ( selectedQueue == null ? null : selectedQueue . getName ( ) ) ; assertEquals ( selectedQueueName , expectedQueueName , message ) ; } catch ( Exception e ) { Assert . fail ( message , e ) ; } }
Tests whether the JobManager.selectQueue method returns the expected queue
 given a set of inputs.
Tests whether the JobManager . selectQueue method returns the expected queue given a set of inputs .