Developer How-To
From Contensive Wiki
Contents
[hide]Setup a Selenium IDE Test Environment
Use these instructions to setup a Selendium-IDE test environment.
- Install the Selenium-IDE Firefox extension
- all tests are saved in the /testcases folder under the appropriate github repo
- all tests should be numbered (test1.html, test2.html, etc) and documented briefly in the wiki documentation page for the project.
- Never run test cases on production sites. We should expect them to be destructive.
- It should be assumed that the root developer login in always available.
- (developers only) When creating a test site, add the following code to the /includes/Contensiveconfig42.php page for the site to eliminate the frameworks serialized form system.
// // bypass form serial numbers for automated testing // $needle = 'ccFormSN" VALUE="'; $snPos = stripos ( $s, $needle, 0 ); while ($snPos !== false ) { $snPos += 17; $needle2 = '">'; $snEnd = stripos( $s, $needle2, $snPos ); $sn = substr($s, $snPos, ($snEnd - $snPos)); $s = str_replace( $sn, "0", $s ); //$s .= '<br>ccFormSN sn=' . $sn; $snPos = stripos ( $s, $needle, $snEnd); } return $s;
To create a new AWS instance
- log into AWS
- Under Images click AMIs
- select Contensive41 --> right click on Contensive41 and launch a new instance
- select general purpose t2.micro --> click next:
- review launch and click next:
- add storage change the size of root to 100gb
- add new volume under device change to xvdf change size to 400gb
- click next
- name the key Use new sever Name
- click next
- In configure security setting select an existing security group
- select production server, windows
- review
- launch
Assign an elastic Ip
- in ec2 select elastic ip
- under actions lallocate new address
- for a windows server select VPC in the EIP dropdown
- under actions associate the IP with the new instance created
Repairing a Microsoft Access Db
Use these steps to compact or repair an Access Db.
- Open the Upgrade folder.
- Shut down Contensive.
- Turn off auto start in application manager.
- Open the folder interpub/db and make a copy of the target database.
- Open odbc32 --> select the system dsn tab --> push ADD --> select the appropriate driver (ms-access driver)--> push finish -->
- select repair and find the newly copied db --> click ok --> close odbc32
- Go back into Interpub and copy the newly repaired db and rename it.
- now go back into odbc32 select the system DSN--> select add to create a new dsn --> select the ms access driver --> select the new db --> give it a new name (typically Incremented) --> click OK
- open app manager and rename the connection string
- restart contensive