File tree 4 files changed +51
-2
lines changed
4 files changed +51
-2
lines changed Original file line number Diff line number Diff line change 1
- [ ![ Build Status] ( https://travis-ci.org/delboy1978uk /php-mpos.png?branch=master )] ( https://travis-ci.org/delboy1978uk /php-mpos ) [ ![ Code Coverage] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/badges/coverage.png?b=master )] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/?branch=master ) [ ![ Scrutinizer Code Quality] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/badges/quality-score.png?b=master )] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/?branch=master ) master<br />
2
- [ ![ Build Status] ( https://travis-ci.org/delboy1978uk /php-mpos.png?branch=development )] ( https://travis-ci.org/delboy1978uk /php-mpos ) [ ![ Code Coverage] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/badges/coverage.png?b=development )] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/?branch=development ) [ ![ Scrutinizer Code Quality] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/badges/quality-score.png?b=development )] ( https://scrutinizer-ci.com/g/delboy1978uk /php-mpos/?branch=development ) development
1
+ [ ![ Build Status] ( https://travis-ci.org/MPOS /php-mpos.png?branch=master )] ( https://travis-ci.org/MPOS /php-mpos ) [ ![ Code Coverage] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/badges/coverage.png?b=master )] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/?branch=master ) [ ![ Scrutinizer Code Quality] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/badges/quality-score.png?b=master )] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/?branch=master ) master<br />
2
+ [ ![ Build Status] ( https://travis-ci.org/MPOS /php-mpos.png?branch=development )] ( https://travis-ci.org/MPOS /php-mpos ) [ ![ Code Coverage] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/badges/coverage.png?b=development )] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/?branch=development ) [ ![ Scrutinizer Code Quality] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/badges/quality-score.png?b=development )] ( https://scrutinizer-ci.com/g/MPOS /php-mpos/?branch=development ) development
3
3
4
4
5
5
Description
Original file line number Diff line number Diff line change @@ -15,3 +15,7 @@ modules:
15
15
user : ' '
16
16
password : ' '
17
17
dump : tests/_data/dump.sql
18
+ coverage :
19
+ whitelist :
20
+ include :
21
+ - include/classes/*
Original file line number Diff line number Diff line change 1
1
<?php
2
2
// This is global bootstrap for autoloading
3
+
4
+ // Set a decently long SECURITY key with special chars etc
5
+ define ('SECURITY ' , '*)WT#&YHfd ' );
6
+ // Whether or not to check SECHASH for validity, still checks if SECURITY defined as before if disabled
7
+ define ('SECHASH_CHECK ' , false );
8
+
9
+ // change SECHASH every second, we allow up to 3 sec back for slow servers
10
+ if (SECHASH_CHECK ) {
11
+ function fip ($ tr =0 ) { return md5 (SECURITY .(time ()-$ tr ).SECURITY ); }
12
+ define ('SECHASH ' , fip ());
13
+ function cfip () { return (fip ()==SECHASH ||fip (1 )==SECHASH ||fip (2 )==SECHASH ) ? 1 : 0 ; }
14
+ } else {
15
+ function cfip () { return (@defined ('SECURITY ' )) ? 1 : 0 ; }
16
+ }
17
+
18
+
19
+ define ("BASEPATH " , dirname (__FILE__ ) . "/ " );
20
+
21
+ define ('INCLUDE_DIR ' , BASEPATH . '../include ' );
22
+ define ('CLASS_DIR ' , INCLUDE_DIR . '/classes ' );
23
+ define ('PAGES_DIR ' , INCLUDE_DIR . '/pages ' );
24
+ define ('TEMPLATE_DIR ' , BASEPATH . '../templates ' );
Original file line number Diff line number Diff line change
1
+ <?php
2
+
3
+ require_once (CLASS_DIR . '/bitcoin.class.php ' );
4
+
5
+ class BitcoinTest extends \Codeception \TestCase \Test
6
+ {
7
+
8
+ public function _before ()
9
+ {
10
+
11
+ }
12
+
13
+ public function _after ()
14
+ {
15
+
16
+ }
17
+
18
+ public function testAddressToHash160 ()
19
+ {
20
+ $ bitcoin = new Bitcoin ();
21
+ $ this ->assertEquals ('82839EADFB204C8D22ED122A0868C6F52B5BDFC9 ' ,$ bitcoin ->addressToHash160 ('1Cu6X3c716CCKU3Bi2jfHv8kZ2QCor8uXm ' ));
22
+ }
23
+ }
You can’t perform that action at this time.
0 commit comments