Esempio n. 1
0
 /**
  * Does basic setting up of Loris variables for this test, such as
  * instantiting the config and database objects, creating a user
  * to user for the tests, and logging in, and creating a candidate
  * with a session
  *
  * @return none
  */
 public function setUp()
 {
     parent::setUp();
     // Create tests-specific data
     $this->DB->insert("psc", array('CenterID' => '253', 'Name' => 'Test Site AOL', 'Alias' => 'AOL', 'MRI_alias' => 'Y'));
     $this->DB->insert("psc", array('CenterID' => '254', 'Name' => 'Test Site BOL', 'Alias' => 'BOL', 'MRI_alias' => 'Y'));
     // Create test-specific data
     $this->DB->insert("candidate", array('CandID' => '000001', 'PSCID' => 'DCC0001', 'CenterID' => 1, 'Active' => 'Y', 'Entity_type' => 'Human'));
     $this->DB->insert("candidate", array('CandID' => '000002', 'PSCID' => 'AOL0002', 'CenterID' => 253, 'Active' => 'Y', 'Entity_type' => 'Human'));
     $this->DB->insert("candidate", array('CandID' => 03, 'PSCID' => 'BOL0003', 'CenterID' => 254, 'Active' => 'Y', 'Entity_type' => 'Human'));
     $this->DB->insert('session', array('ID' => 999997, 'CandID' => 01, 'Visit_label' => 'Test0', 'CenterID' => 1, 'Scan_done' => 'Y', 'Current_stage' => 'Visit', 'Visit' => 'In Progress'));
     $this->DB->insert('session', array('ID' => 999998, 'CandID' => 02, 'Visit_label' => 'Test1', 'CenterID' => 253, 'Scan_done' => 'Y', 'Current_stage' => 'Visit', 'Visit' => 'In Progress'));
     $this->DB->insert('session', array('ID' => 999999, 'CandID' => 03, 'Visit_label' => 'Test2', 'CenterID' => 254, 'Scan_done' => 'Y', 'Current_stage' => 'Visit', 'Visit' => 'In Progress'));
     // Add imaging data
     $this->DB->insert('mri_processing_protocol', array('ProcessProtocolID' => 1, 'ProtocolFile' => 'None1', 'FileType' => null, 'Tool' => 'None1', 'InsertTime' => 0, 'md5sum' => null));
     $this->DB->insert('mri_processing_protocol', array('ProcessProtocolID' => 2, 'ProtocolFile' => 'None2', 'FileType' => null, 'Tool' => 'None2', 'InsertTime' => 0, 'md5sum' => null));
     // @codingStandardsIgnoreStart
     $this->DB->insert('files', array('FileID' => 1, 'SessionID' => 999998, 'File' => 'assembly/506145/V1/mri/native/' . 'loris-MRI_506145_V1_t2_001.mnc', 'SeriesUID' => '1.3.12.2.1107.5.2.32.35049.' . '2014021711090977356751313.0.0.0', 'EchoTime' => 0.011, 'CoordinateSpace' => 'native', 'OutputType' => 'native', 'AcquisitionProtocolID' => 45, 'FileType' => 'mnc', 'PendingStaging' => 0, 'InsertedByUserID' => 'lorisadmin', 'InsertTime' => 1454951768, 'SourcePipeline' => null, 'PipelineDate' => null, 'SourceFileID' => 1, 'ProcessProtocolID' => 1, 'Caveat' => 0, 'TarchiveSource' => 263));
     // @codingStandardsIgnoreEnd
     // @codingStandardsIgnoreStart
     $this->DB->insert('files', array('FileID' => 2, 'SessionID' => 999999, 'File' => 'assembly/506145/V1/mri/native/' . 'loris-MRI_506145_V1_t1_001.mnc', 'SeriesUID' => '1.3.12.2.1107.5.2.32.35049.' . '2014021711090977356751313.0.0.0', 'EchoTime' => 0.011, 'CoordinateSpace' => 'native', 'OutputType' => 'native', 'AcquisitionProtocolID' => 44, 'FileType' => 'mnc', 'PendingStaging' => 0, 'InsertedByUserID' => 'lorisadmin', 'InsertTime' => 1454951768, 'SourcePipeline' => null, 'PipelineDate' => null, 'SourceFileID' => 2, 'ProcessProtocolID' => 2, 'Caveat' => 0, 'TarchiveSource' => 263));
     // @codingStandardsIgnoreStart
     $this->DB->insert('mri_acquisition_dates', array('SessionID' => 999998, 'AcquisitionDate' => '2014-02-17'));
     $this->DB->insert('mri_acquisition_dates', array('SessionID' => 999999, 'AcquisitionDate' => '2014-02-17'));
     $this->DB->insert('files_qcstatus', array('FileQCID' => 1, 'FileID' => 1, 'SeriesUID' => '1.3.12.2.1107.5.2.32.35049.' . '2014021711090977356751313.0.0.0', 'EchoTime' => 0.011, 'QCStatus' => null, 'QCFirstChangeTime' => 1455040145, 'QCLastChangeTime' => 1455040145, 'Selected' => 't2'));
     $this->DB->insert('files_qcstatus', array('FileQCID' => 2, 'FileID' => 2, 'SeriesUID' => '1.3.12.2.1107.5.2.32.35049.' . '2014021711090977356751313.0.0.0', 'EchoTime' => 0.011, 'QCStatus' => null, 'QCFirstChangeTime' => 1455040145, 'QCLastChangeTime' => 1455040145, 'Selected' => 't1'));
 }
Esempio n. 2
0
 /**
  * Insert testing data
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $size = new WebDriverDimension(1024, 1768);
     $window->setSize($size);
     $this->DB->insert("psc", array('CenterID' => '9999999', 'Name' => 'TEST_Site', 'Study_site' => 'Y', 'StateID' => '0', 'Alias' => 'DDD', 'MRI_alias' => 'TESTTEST'));
 }
Esempio n. 3
0
 /**
  * Insert testing data into the database
  *
  * @return none
  */
 function setUp()
 {
     parent::setUp();
     $md5String = md5("TestTestTest");
     $window = new WebDriverWindow($this->webDriver);
     $window->maximize();
     $this->DB->insert("help", array('helpID' => '999999', 'parentID' => '-1', 'hash' => $md5String, 'topic' => 'Test Topic', 'content' => 'This is a test content.', 'created' => '2013-04-05 00:00:00', 'updated' => 'NULL'));
 }
Esempio n. 4
0
 /**
  * Insert testing data into the database
  * author: Wang Shen
  *
  * @return none
  */
 function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $window->maximize();
     $this->DB->insert("conflicts_resolved", array('ResolvedID' => '999999', 'UserID' => 'demo', 'ResolutionTimestamp' => '2015-11-03 16:21:49', 'User1' => 'Null', 'User2' => 'Null', 'TableName' => 'Test', 'ExtraKey1' => 'NULL', 'ExtraKey2' => 'NULL', 'FieldName' => 'TestTestTest', 'CommentId1' => '589569DCC000012291366553230', 'CommentId2' => 'DDE_589569DCC000012291366653254', 'OldValue1' => 'Mother', 'OldValue2' => 'Father', 'NewValue' => 'NULL', 'ConflictID' => 'NULL'));
     $this->DB->insert("conflicts_unresolved", array('TableName' => 'TestTestTest', 'ExtraKeyColumn' => 'Test', 'ExtraKey1' => 'Null', 'ExtraKey2' => 'Null', 'FieldName' => 'TestTestTest', 'CommentId1' => '963443000111271151398976899', 'Value1' => 'no', 'CommentId2' => 'DDE_963443000111271151398976899', 'Value2' => 'no'));
 }
Esempio n. 5
0
 /**
  * Insert testing data into the database
  *
  * @return none
  */
 function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $size = new WebDriverDimension(1024, 1768);
     $window->setSize($size);
     $this->DB->insert("tarchive", array('DicomArchiveID' => '9999999999', 'PatientID' => '9999999999', 'PatientName' => 'TestTestTest', 'PatientDoB' => '1900-01-01', 'PatientGender' => 'M', 'neurodbCenterName' => 'NULL', 'CenterName' => 'Mc Gill University', 'LastUpdate' => '2014-05-30 13:49:36', 'DateAcquired' => '2010-11-25', 'DateFirstArchived' => '2014-05-30 13:47:11', 'DateLastArchived' => '2014-05-30 13:49:36', 'AcquisitionCount' => '166', 'NonDicomFileCount' => '0', 'DicomFileCount' => '881', 'md5sumDicomOnly' => '5.150346.tar', 'md5sumArchive' => '5.150346.tar', 'CreatingUser' => 'lorisadmin', 'sumTypeVersion' => '1', 'tarTypeVersion' => '1', 'SourceLocation' => '/tmp/bEu0Q_egfA/5.150346', 'ArchiveLocation' => '2010/DCM5.150346.tar', 'ScannerManufacturer' => 'SIEMENS', 'ScannerModel' => 'TrioTim', 'ScannerSerialNumber' => '35056', 'ScannerSoftwareVersion' => 'syngo MR B15', 'SessionID' => '44', 'uploadAttempt' => '0', 'CreateInfo' => 'NULL'));
 }
Esempio n. 6
0
 /**
  * Does basic setting up of Loris variables for this test,after testing
  * a test data, remove the testing data from database.
  *
  * @return none
  */
 public function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $size = new WebDriverDimension(1024, 1768);
     $window->setSize($size);
     $this->DB->insert("document_repository_categories", array('id' => '9999999', 'category_name' => 'TESTTESTTESTTEST', 'parent_id' => '0', 'comments' => 'Test Comment'));
     $this->DB->insert("document_repository", array('record_id' => '9999999', 'Date_uploaded' => '2016-05-16 15:34:35', 'Data_dir' => 'admin/README.md', 'File_name' => 'README.md', 'File_type' => 'NULL', 'File_size' => '3305', 'uploaded_by' => 'admin', 'For_site' => '3', 'comments' => 'tester', 'multipart' => 'NULL', 'EARLI' => '0', 'hide_video' => '0', 'File_category' => '9999999'));
 }
Esempio n. 7
0
 /**
  * Insert testing data
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $size = new WebDriverDimension(1024, 768);
     $window->setSize($size);
     $this->DB->insert("psc", array('CenterID' => '55', 'Name' => 'TESTinPSC', 'Alias' => 'test', 'MRI_alias' => 'test'));
     $this->DB->insert("candidate", array('CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'PSCID' => '8888', 'ProjectID' => '7777'));
     $this->DB->insert("session", array('ID' => '111111', 'CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'MRIQCStatus' => 'Pass', 'SubprojectID' => '6666', 'Visit' => 'In Progress'));
     $this->DB->insert("candidate", array('CandID' => '999999', 'CenterID' => '55', 'UserID' => '1', 'PSCID' => '8889', 'ProjectID' => '7777'));
     $this->DB->insert("session", array('ID' => '111112', 'CandID' => '999999', 'CenterID' => '55', 'UserID' => '1', 'MRIQCStatus' => 'Pass', 'SubprojectID' => '6666', 'Visit' => 'In Progress'));
     $this->DB->insert("participant_accounts", array('SessionID' => '111111', 'Email' => '*****@*****.**', 'Test_name' => 'Test', 'Status' => 'In Progress', 'OneTimePassword' => 'Test'));
 }
Esempio n. 8
0
 /**
  * Insert testing data
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $size = new WebDriverDimension(1024, 768);
     $window->setSize($size);
     $this->DB->insert("psc", array('CenterID' => '55', 'Name' => 'TESTinPSC', 'Alias' => 'test', 'MRI_alias' => 'test'));
     $this->DB->insert("candidate", array('CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'PSCID' => '8888', 'ProjectID' => '7777'));
     $this->DB->insert("session", array('CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'MRIQCStatus' => 'Pass', 'SubprojectID' => '6666'));
     $this->DB->insert("mri_protocol_violated_scans", array('ID' => '1001', 'CandID' => '999888', 'PatientName' => '[Test]PatientName', 'time_run' => '2009-06-29 04:00:44', 'minc_location' => 'assembly/test/test/mri/test/test.mnc', 'series_description' => 'Test Series Description', 'SeriesUID' => '5555'));
     $this->DB->insert("mri_protocol_violated_scans", array('ID' => '1002', 'CandID' => '999888', 'PatientName' => '[Test]PatientName', 'time_run' => '2008-06-29 04:00:44', 'minc_location' => 'assembly/test2/test2/mri/test2/test2.mnc', 'series_description' => 'Test Series Description', 'SeriesUID' => '5556'));
     $this->DB->insert("violations_resolved", array('ExtID' => '1001', 'TypeTable' => 'mri_protocol_violated_scans', 'Resolved' => 'other'));
     $this->DB->insert("violations_resolved", array('ExtID' => '1002', 'TypeTable' => 'MRICandidateErrors', 'Resolved' => 'unresolved'));
     $this->DB->insert("MRICandidateErrors", array('ID' => '1002', 'PatientName' => '[Test]PatientName', 'MincFile' => 'assembly/test2/test2/mri/test2/test2.mnc', 'SeriesUID' => '5556'));
 }
Esempio n. 9
0
 /**
  * Insert testing data
  *
  * @return void
  */
 public function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $size = new WebDriverDimension(1280, 720);
     $window->setSize($size);
     $this->DB->insert("psc", array('CenterID' => '55', 'Name' => 'TESTinPSC', 'Alias' => 'test', 'MRI_alias' => 'test'));
     $this->DB->insert("candidate", array('CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'PSCID' => '8888', 'ProjectID' => '7777', 'Gender' => 'Male'));
     $this->DB->insert("candidate", array('CandID' => '999889', 'CenterID' => '55', 'UserID' => '1', 'PSCID' => '8889', 'ProjectID' => '7777', 'Gender' => 'Female'));
     $this->DB->insert("session", array('ID' => '111111', 'CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'MRIQCStatus' => 'Pass', 'SubprojectID' => '6666'));
     $this->DB->insert("session", array('ID' => '111112', 'CandID' => '999889', 'CenterID' => '55', 'UserID' => '1', 'MRIQCStatus' => 'Pass', 'SubprojectID' => '6666'));
     $this->DB->insert("reliability", array('ID' => '111111112', 'CommentID' => 'testCommentID1', 'Instrument' => 'testInstrument'));
     $this->DB->insert("reliability", array('ID' => '111111113', 'CommentID' => 'testCommentID2', 'Instrument' => 'testInstrument'));
     $this->DB->insert("test_names", array('ID' => '111111113', 'Test_name' => 'test_name'));
     $this->DB->insert("flag", array('ID' => '111111111', 'SessionID' => '111111', 'CommentID' => 'testCommentID1', 'Test_name' => 'test_name'));
     $this->DB->insert("flag", array('ID' => '111111112', 'SessionID' => '111112', 'CommentID' => 'testCommentID2', 'Test_name' => 'test_name'));
 }
Esempio n. 10
0
 /**
  * Setup the screen size of Travis-cs
  *
  * @return void
  */
 function setUp()
 {
     parent::setUp();
     $window = new WebDriverWindow($this->webDriver);
     $size = new WebDriverDimension(1280, 1024);
     $window->setSize($size);
     //Insert a pending user
     $this->DB->insert("users", array('UserID' => 'testUser1', 'Email' => '*****@*****.**', 'Password' => 'AA1234567!', 'CenterID' => '1', 'Password_expiry' => '2020-01-06'));
     //Insert two violation scan
     $this->DB->insert("psc", array('CenterID' => '55', 'Name' => 'TESTinPSC', 'Alias' => 'test', 'MRI_alias' => 'test'));
     $this->DB->insert("candidate", array('CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'PSCID' => '8888', 'ProjectID' => '7777', 'Entity_type' => 'Human'));
     $this->DB->insert("session", array('ID' => '222222', 'CandID' => '999888', 'CenterID' => '55', 'UserID' => '1', 'MRIQCStatus' => 'Pass', 'SubprojectID' => '6666'));
     $this->DB->insert("mri_protocol_violated_scans", array('ID' => '1001', 'CandID' => '999888', 'PatientName' => '[Test]PatientName', 'time_run' => '2009-06-29 04:00:44', 'minc_location' => 'assembly/test/test/mri/test/test.mnc', 'series_description' => 'Test Series Description', 'SeriesUID' => '5555'));
     $this->DB->insert("mri_protocol_violated_scans", array('ID' => '1002', 'CandID' => '999888', 'PatientName' => '[Test]PatientName', 'time_run' => '2008-06-29 04:00:44', 'minc_location' => 'assembly/test2/test2/mri/test2/test2.mnc', 'series_description' => 'Test Series Description', 'SeriesUID' => '5556'));
     $this->DB->insert("violations_resolved", array('ExtID' => '1001', 'TypeTable' => 'mri_protocol_violated_scans', 'Resolved' => 'other'));
     $this->DB->insert("violations_resolved", array('ExtID' => '1002', 'TypeTable' => 'MRICandidateErrors', 'Resolved' => 'unresolved'));
     $this->DB->insert("MRICandidateErrors", array('ID' => '1002', 'PatientName' => '[Test]PatientName', 'MincFile' => 'assembly/test2/test2/mri/test2/test2.mnc', 'SeriesUID' => '5556'));
     //Insert an incomplete form data
     $this->DB->insert("test_names", array('ID' => '111', 'Test_name' => 'TestName11111111111'));
     $this->DB->insert("flag", array('ID' => '111111', 'SessionID' => '222222', 'Test_name' => 'TestName11111111111', 'CommentID' => 'commentID111', 'Data_entry' => 'In Progress'));
     //Insert a demo data into conflicts_unresolved
     $this->DB->insert("conflicts_unresolved", array('TableName' => 'TestTestTest', 'ExtraKeyColumn' => 'Test', 'ExtraKey1' => 'Null', 'ExtraKey2' => 'Null', 'FieldName' => 'TestTestTest', 'CommentId1' => '963443000111271151398976899', 'Value1' => 'no', 'CommentId2' => 'DDE_963443000111271151398976899', 'Value2' => 'no'));
 }
Esempio n. 11
0
 /**
  * Insert testing data into the database
  *
  * @return none
  */
 function setUp()
 {
     parent::setUp();
     $this->DB->insert("data_integrity_flag", array('dataflag_id' => '9999999', 'dataflag_visitlabel' => 'V_test', 'dataflag_instrument' => 'test_instrument', 'dataflag_date' => '2015-12-03', 'dataflag_status' => '4', 'dataflag_comment' => '33', 'latest_entry' => '1', 'dataflag_fbcreated' => '0', 'dataflag_fbclosed' => '0', 'dataflag_fbcomment' => '0', 'dataflag_fbdeleted' => '0', 'dataflag_userid' => 'test_user'));
 }
Esempio n. 12
0
 function setUp()
 {
     parent::setUp();
     $this->DB->insert("parameter_type", array('Name' => 'TestParameterNotRealMAGICNUMBER335', 'Type' => 'varchar(255)', 'Description' => 'I am a fake description used only for testing you should not see me. MAGICNUMBER335', 'SourceFrom' => 'nowhere', 'SourceField' => 'imaginary', 'Queryable' => true, 'IsFile' => 0));
 }