From fa2f1c171bd20c8b330ef6fb4863dd01df43ec23 Mon Sep 17 00:00:00 2001 From: Steph Fox Date: Fri, 1 Aug 2008 17:34:03 +0000 Subject: [PATCH] - Somehow 'cvs add' managed to ignore these completely(?) --- .../cache_list/files/frontcontroller.phar | Bin 0 -> 331 bytes .../cache_list/files/frontcontroller10.phar | Bin 0 -> 591 bytes .../cache_list/files/frontcontroller11.phar | Bin 0 -> 578 bytes .../cache_list/files/frontcontroller12.phar | Bin 0 -> 581 bytes .../cache_list/files/frontcontroller13.phar | Bin 0 -> 330 bytes .../cache_list/files/frontcontroller14.phar | Bin 0 -> 448 bytes .../cache_list/files/frontcontroller16.phar | Bin 0 -> 330 bytes .../cache_list/files/frontcontroller17.phar | Bin 0 -> 315 bytes .../cache_list/files/frontcontroller18.phar | Bin 0 -> 331 bytes .../cache_list/files/frontcontroller19.phar | Bin 0 -> 560 bytes .../cache_list/files/frontcontroller2.phar | Bin 0 -> 297 bytes .../cache_list/files/frontcontroller3.phar | Bin 0 -> 446 bytes .../cache_list/files/frontcontroller4.phar | Bin 0 -> 442 bytes .../cache_list/files/frontcontroller5.phar | Bin 0 -> 327 bytes .../cache_list/files/frontcontroller6.phar | Bin 0 -> 328 bytes .../cache_list/files/frontcontroller7.phar | Bin 0 -> 329 bytes .../cache_list/files/frontcontroller8.phar | Bin 0 -> 8968 bytes .../cache_list/files/frontcontroller9.phar | Bin 0 -> 448 bytes .../tests/cache_list/frontcontroller1.phpt | 17 ++++++++++++ .../tests/cache_list/frontcontroller10.phpt | 25 ++++++++++++++++++ .../tests/cache_list/frontcontroller11.phpt | 22 +++++++++++++++ .../tests/cache_list/frontcontroller12.phpt | 21 +++++++++++++++ .../tests/cache_list/frontcontroller13.phpt | 21 +++++++++++++++ .../tests/cache_list/frontcontroller14.phpt | 17 ++++++++++++ .../tests/cache_list/frontcontroller15.phpt | 21 +++++++++++++++ .../tests/cache_list/frontcontroller16.phpt | 18 +++++++++++++ .../tests/cache_list/frontcontroller17.phpt | 18 +++++++++++++ .../tests/cache_list/frontcontroller18.phpt | 18 +++++++++++++ .../tests/cache_list/frontcontroller19.phpt | 18 +++++++++++++ .../tests/cache_list/frontcontroller2.phpt | 17 ++++++++++++ .../tests/cache_list/frontcontroller20.phpt | 18 +++++++++++++ .../tests/cache_list/frontcontroller21.phpt | 25 ++++++++++++++++++ .../tests/cache_list/frontcontroller22.phpt | 22 +++++++++++++++ .../tests/cache_list/frontcontroller23.phpt | 18 +++++++++++++ .../tests/cache_list/frontcontroller24.phpt | 17 ++++++++++++ .../tests/cache_list/frontcontroller25.phpt | 18 +++++++++++++ .../tests/cache_list/frontcontroller26.phpt | 16 +++++++++++ .../tests/cache_list/frontcontroller27.phpt | 17 ++++++++++++ .../tests/cache_list/frontcontroller28.phpt | 17 ++++++++++++ .../tests/cache_list/frontcontroller29.phpt | 17 ++++++++++++ .../tests/cache_list/frontcontroller3.phpt | 20 ++++++++++++++ .../tests/cache_list/frontcontroller30.phpt | 14 ++++++++++ .../tests/cache_list/frontcontroller31.phpt | 16 +++++++++++ .../tests/cache_list/frontcontroller32.phpt | 16 +++++++++++ .../tests/cache_list/frontcontroller33.phpt | 16 +++++++++++ .../tests/cache_list/frontcontroller34.phpt | 19 +++++++++++++ .../tests/cache_list/frontcontroller4.phpt | 15 +++++++++++ .../tests/cache_list/frontcontroller5.phpt | 16 +++++++++++ .../tests/cache_list/frontcontroller6.phpt | 23 ++++++++++++++++ .../tests/cache_list/frontcontroller7.phpt | 16 +++++++++++ .../tests/cache_list/frontcontroller8.phpt | 23 ++++++++++++++++ .../tests/cache_list/frontcontroller9.phpt | 20 ++++++++++++++ 52 files changed, 632 insertions(+) create mode 100644 ext/phar/tests/cache_list/files/frontcontroller.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller10.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller11.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller12.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller13.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller14.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller16.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller17.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller18.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller19.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller2.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller3.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller4.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller5.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller6.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller7.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller8.phar create mode 100644 ext/phar/tests/cache_list/files/frontcontroller9.phar create mode 100644 ext/phar/tests/cache_list/frontcontroller1.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller10.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller11.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller12.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller13.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller14.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller15.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller16.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller17.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller18.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller19.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller2.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller20.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller21.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller22.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller23.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller24.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller25.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller26.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller27.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller28.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller29.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller3.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller30.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller31.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller32.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller33.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller34.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller4.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller5.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller6.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller7.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller8.phpt create mode 100644 ext/phar/tests/cache_list/frontcontroller9.phpt diff --git a/ext/phar/tests/cache_list/files/frontcontroller.phar b/ext/phar/tests/cache_list/files/frontcontroller.phar new file mode 100644 index 0000000000000000000000000000000000000000..626bf48acf0596c465b08772ececb62bc52409e5 GIT binary patch literal 331 zcmcDqFUTn13dl$-va%{qO#(4AG_AQ(lQZ%al=AZniWO2aQxx*@OB9Mq^J4Opthve( zi{evCa|<+7;$8j1bQDzLgI$BdT!VnR;^RFWeL~`${e1&GeO!Zp1}WIv@p8>(U|?VY zVnHBg1Y!ta1yYH6K--yt49>rG?jU;Y`|TIDLDfJMWEG_2Qosf?p;!!R1c(;SX-t3_ z!3pGN=B1=ofb0=~Dgx0{k9i8f6lG-Q1Cb3VAQaL{^O8$4^YavdA{v_2wHc{JsS26J m3b~aEU~?i)w7y^CxL!rRxl^>>fZbuj4HIT2pn2|2zD@vN!&S2Y literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller10.phar b/ext/phar/tests/cache_list/files/frontcontroller10.phar new file mode 100644 index 0000000000000000000000000000000000000000..078ce75b2c7bf54b0c1c897613a8b347990a22ef GIT binary patch literal 591 zcmcDqFUTn13dl$-va-r8%}WnXEhH@p$Sm_!Iye>5N+Ro`pY(u zdLXa?dmqV4h+WYLpT`32#UhU!8u*pKLkNd5|ac_!JT0EU;lvb%fjo lR*UXHjrPfGk1B$m)n5;txmAT&df_mtsB(=B%q|O+s4n(s# z-HL*#FGo4#nh6K2{d2v!C~ts?CX|TExK@M)w0-XFWuMMnSf4nck*=t00V|y Af&c&j literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller14.phar b/ext/phar/tests/cache_list/files/frontcontroller14.phar new file mode 100644 index 0000000000000000000000000000000000000000..78a42a999f0754ed4d008f3da32c16eb4f280d22 GIT binary patch literal 448 zcmZ`#KTE?v6t9i}1s5G$j-yBd!Q$E$OR7mzNYj|4T~vpfL~Q96aa2RYGQzfc z)KeXo^z1g4zBOZdRv3$T9C#T8X+ixPFC&&mk&G6u5-?H>4s;O22*+`fB0uyIi!;P? zcEX_U$m7J%hlyAws@a!O8EV*l)dm$Ix?;HGpxd$9hH687)YxAW>ZMX?1!iNpVFA`* ze&51`m+9?itJs?_@yZEOIU3?1Z{}EhUF&#s3)x$Y$mh64p Z-!$Lvp0{UD-rMWrwa^E2LzmDCFgrC=`|E z0cEYZ$`Xs>Q%Z9SG*seU{latcfcoO&Jsf>P;+_3{13Z0PgETa)73}SJ zxy%_D7#M+A5K03nAm9XIxR*duw=?)XK(trbmF{gI^*~?)4jhPUGBSa-Zw|O~@_L%q Z{hHsu?oJKRHD49B#fu53(A~+`2>^aBUe^Es literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller17.phar b/ext/phar/tests/cache_list/files/frontcontroller17.phar new file mode 100644 index 0000000000000000000000000000000000000000..b83d41fd5b8dc4be713bd8f0961d1b1835535ab0 GIT binary patch literal 315 zcmcDqFUTn1Dk-W|sOAdDNG!6lDo;%UF*KA)Qj1IU3V=){9R(%*%)FG;3Lv)t$jd9u z$mLz8=Xt-7+rxuiC=I1G>q-p|9PRUHwP)XIb zOHVEFO)V}?Oi$I&RM1mUipc|O<4R4=$X8Ix&o3xeNXbl5$jdKLC@ReZ%35=kB^Je} zl;##_sKmSah3P1$#0R?ug}DX+t&5NMaP$d@clP%U@bqyF($KV4u(#voGG}05U<6`8 zC=H~5fD?$}egH|`&EWR{(OzL!y0?MU1Az@VG$5|Y$OPK{^4%Qi{KVtuJ$9{X;Ep<= Q6kXB3g$bz8-O1Mp0Hn}aTL1t6 literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller18.phar b/ext/phar/tests/cache_list/files/frontcontroller18.phar new file mode 100644 index 0000000000000000000000000000000000000000..c447f397ac54afbc9828a82db9f8c5cff567acbc GIT binary patch literal 331 zcmcDqFUTn1N-NDvF3HT#Qz+I@Nz~-3=Bni?DXLVc<_gG2EV8mHPfY?bG?YqGi%awh zfJ`MF1ttB=yp+@mAh!U>%PY;v(NRb&DoU)>&;&{rD`{GD)hZ+>mLz8=Xt-7+rxt)M zP)XGU8k>@ts-cpqYnPr{;+tAroS2@fp{by!pcIn_*2a~ZoRP1fl%HQvtdNqKqL7zg zqEJ+t2b8tuDoZSiPbtkU&`^nY^$XKcP>BzA4GMD&0$LXz@8ReZ67THq8{p~V8l<6V ztzd7*%Vo~Mz`zK^f>0Vr0Rblv!#x0!(!4C;0iwOau5@n$sRsfZaOgl>laUFu{l1rB dg3v_U8~YfFj<~aN`(AU{n9c-L=JKNG!6_*H==|Q;3gu^Yn3zkJq&3Dk-W| zsOAa)$yt@BCV?0lN+qeqC3+zBN;(Qk`o$%QMJ4)~c`2zCK*0hfpsrel zisaOSlFa-(1(j4ypg}2_sTwM&x_0TQCBCV}#fj;u8k#^0m16S1+PG4aGx8Ob^79Ld z6;d)&6!P**6pBjofU?$HWr;=cDW$mu8Y=OweqlNaD)GUtL1C^zKP;+_3{ z1Ay)h($KV4u(#von#jPwzzoEKK+Fil5Wo+l(41@u6jFRI;Q^vOZcg{x22~Bx2vM2{ zbV){P5y*dbP{km+hU>;>m||`qA4!=UR2hg)+S@$~rpyK${1AVlIRorXXrw48>FFbx z2J}CsMkIMOt>}8~?T~e&>$A73p0g%#n&GW_@0Bw{JkxeQmk&9m#RPP?yOXaI0HCp@ AAOHXW literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller2.phar b/ext/phar/tests/cache_list/files/frontcontroller2.phar new file mode 100644 index 0000000000000000000000000000000000000000..0dd0e7f695629841ce0c4cac30f4960dc5e60547 GIT binary patch literal 297 zcmcDqFUTn13dl$-va%{qO#(4Al*%&_OH#{HiQ%Z9SG*seU{latcfV$%2Jsf>P;+_3{ z13Z0PgETa)73}SJxyl$A7?^=r5QrIp7y?*<6xcqHR1b5#JBVKUe*1-OP&E(*Sq161 z6tKZeC>Dbn0iuO-8WUhfWMt+8kqyY(3TdTz$t9Wjc?v)g4bAG>+iOl2www-T(7D~c U!01QBw~0y`x0rzX-JN`$0E>lB3;+NC literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller3.phar b/ext/phar/tests/cache_list/files/frontcontroller3.phar new file mode 100644 index 0000000000000000000000000000000000000000..afcf03af35117e22eda4011a818af5a205a5dbd7 GIT binary patch literal 446 zcmcDqFUTn1MYP)XF}<*Mf8QUHSDlEjkCWCfKZ1zUy0qN2n~4JG}I zOeFS5Uz?I0y&7_d02ATNYR70{$fjLg;q z8)M6Lj(T~p+!LqUbGlmRy3K>usarp8cMe-l7u!XsR+J={%dIKjRKB8oVe2Xoy@rNn zvzLaB&)@I!w~VtOT*p`c5jK_`rTqMYVkJ#YYp&GfjC=@JAtf_KAuqo~p{O)3CQr$lt1Pi7KBY9bKtm|oDSgim6 literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller7.phar b/ext/phar/tests/cache_list/files/frontcontroller7.phar new file mode 100644 index 0000000000000000000000000000000000000000..07884b22bc291adee25c84c1a1671d1f60af320c GIT binary patch literal 329 zcmcDqFUTn13dl$-va%{qO#(4Al*%&_OH#{Hi|DL=oUSRo}dMIkT0M4_lOFD6gPnyW0aC_be$w?IQB z-qkNmM?ob%*fl83H3+CHKHkI8CnVn4-#5V1$2CYp(^|paj+d*9fq{V;hy{U|5r`px z6-Xt5+yatvN^bE0(QDstzpxFe2BILVARU(iHkb*;Vo)PMv~W&i0?dev%zPlS0R@Xf vT4`Q#NoIbY0#HOlv%0o_$Mt;)o&m?3%mc>;Wy9B{$`IepK5t6Gv^UG zH`k#R-ALe$M*_Mf1@Pk$zqZ$+D+2;2+w#_Xf-D-QYm6&v$m9=R!=@y*) znv++fTsOVATy$@)W^RkvO(ZtLENri~c {kB~zeNve;H*LeS_^7d~)&2lEJp!0O|;r$3Ws@`i-@J6z( zpYb{q-|2@4(`yMOp9(AK?7y7&5g~dlT+nWCAOv*2IsfcS1n8;Syun3>ClxjxVmdE8 zesv;_Ram{onlu@7gAp{eqjP8P;JFApZm5NmfHbL;LJlm&E1KW-b|TbcVrE|dPbju| z!(Cg)dFM{aDHPpOK7-4DwsRfl7K>>&vvO+{mn~bBxI8RTYx9kO364}(!rJbuxRUK5 zB?mDdNz$Rd*rXo&XF}{TY}o`ZFaQR?02lxRU;qq&0WbgtzyKHk17H9QfB`T72EYIq z00UqE41fVJ00zJS7ytuc;Qu!;JQbi1mN4p83G;jEl*rw$&wuWYUVSqDt4yb!y4xRL OTsx}|PuyP0F6{&4`ryw1 literal 0 HcmV?d00001 diff --git a/ext/phar/tests/cache_list/files/frontcontroller9.phar b/ext/phar/tests/cache_list/files/frontcontroller9.phar new file mode 100644 index 0000000000000000000000000000000000000000..39ca28c96cfaec73cc9f195aece427d0228305fb GIT binary patch literal 448 zcmcDqFUTn13dl$-va-r8%}WnXEh%~eKodZE zK?>nw!5}MBlQZ%al=AZniWO2aQxx*@OB9Mq^J4Opthve(i{evCa|<+7;$8j1bQDzL zgI$BdT!VnR;^RFWeL~`${e1&GeO!YyG_4iv?RdH7GB7Z(0I?ttGXgOLumPz=kkgAn za;Hx7cz|f$_H6BKP(`d@6+oXLE7*Q5X%ngfpb=tF6F{_ZPGbU00XLAJR+OKYt(OiW zkDtgZ!8##VD +--ENV-- +SCRIPT_NAME=/frontcontroller1.php +REQUEST_URI=/frontcontroller1.php/a.jpg +PATH_INFO=/a.jpg +--FILE_EXTERNAL-- +files/frontcontroller.phar +--EXPECTHEADERS-- +Content-type: image/jpeg +Content-length: 3 +--EXPECT-- +hio diff --git a/ext/phar/tests/cache_list/frontcontroller10.phpt b/ext/phar/tests/cache_list/frontcontroller10.phpt new file mode 100644 index 0000000000..00177d4ff5 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller10.phpt @@ -0,0 +1,25 @@ +--TEST-- +Phar front controller rewrite access denied [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller10.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller10.php +REQUEST_URI=/frontcontroller10.php/hi +PATH_INFO=/hi +--FILE_EXTERNAL-- +files/frontcontroller4.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +Status: 403 Access Denied +--EXPECT-- + + + Access Denied + + +

403 - File /hi Access Denied

+ + diff --git a/ext/phar/tests/cache_list/frontcontroller11.phpt b/ext/phar/tests/cache_list/frontcontroller11.phpt new file mode 100644 index 0000000000..25b147e194 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller11.phpt @@ -0,0 +1,22 @@ +--TEST-- +Phar front controller mime type extension is not a string [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller11.php +--SKIPIF-- + + +--ENV-- +SCRIPT_NAME=/frontcontroller11.php +REQUEST_URI=/frontcontroller11.php/a.php +PATH_INFO=/a.php +--FILE_EXTERNAL-- +files/frontcontroller5.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +Fatal error: Uncaught exception 'PharException' with message 'Key of MIME type overrides array must be a file extension, was "0"' in %sfrontcontroller11.php:2 +Stack trace: +#0 %sfrontcontroller11.php(2): Phar::webPhar('whatever', 'index.php', '', Array) +#1 {main} + thrown in %sfrontcontroller11.php on line 2 \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller12.phpt b/ext/phar/tests/cache_list/frontcontroller12.phpt new file mode 100644 index 0000000000..cfc7d0e43a --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller12.phpt @@ -0,0 +1,21 @@ +--TEST-- +Phar front controller mime type unknown int [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller12.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller12.php +REQUEST_URI=/frontcontroller12.php/a.php +PATH_INFO=/a.php +--FILE_EXTERNAL-- +files/frontcontroller6.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +Fatal error: Uncaught exception 'PharException' with message 'Unknown mime type specifier used, only Phar::PHP, Phar::PHPS and a mime type string are allowed' in %sfrontcontroller12.php:2 +Stack trace: +#0 %sfrontcontroller12.php(2): Phar::webPhar('whatever', 'index.php', '', Array) +#1 {main} + thrown in %sfrontcontroller12.php on line 2 \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller13.phpt b/ext/phar/tests/cache_list/frontcontroller13.phpt new file mode 100644 index 0000000000..e6c9dee4ae --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller13.phpt @@ -0,0 +1,21 @@ +--TEST-- +Phar front controller mime type not string/int [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller13.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller13.php +REQUEST_URI=/frontcontroller13.php/a.php +PATH_INFO=/a.php +--FILE_EXTERNAL-- +files/frontcontroller7.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +Fatal error: Uncaught exception 'PharException' with message 'Unknown mime type specifier used (not a string or int), only Phar::PHP, Phar::PHPS and a mime type string are allowed' in %sfrontcontroller13.php:2 +Stack trace: +#0 %sfrontcontroller13.php(2): Phar::webPhar('whatever', 'index.php', '', Array) +#1 {main} + thrown in %sfrontcontroller13.php on line 2 \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller14.phpt b/ext/phar/tests/cache_list/frontcontroller14.phpt new file mode 100644 index 0000000000..bbd9637d24 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller14.phpt @@ -0,0 +1,17 @@ +--TEST-- +Phar front controller mime type override, other [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller14.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller14.php +REQUEST_URI=/frontcontroller14.php/a.jpg +PATH_INFO=/a.jpg +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: foo/bar +Content-length: 4 +--EXPECT-- +hio2 diff --git a/ext/phar/tests/cache_list/frontcontroller15.phpt b/ext/phar/tests/cache_list/frontcontroller15.phpt new file mode 100644 index 0000000000..d142a5d742 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller15.phpt @@ -0,0 +1,21 @@ +--TEST-- +Phar front controller mime type override, Phar::PHPS [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller15.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller15.php +REQUEST_URI=/frontcontroller15.php/a.php +PATH_INFO=/a.php +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECT-- + +<?php function hio(){} + + + diff --git a/ext/phar/tests/cache_list/frontcontroller16.phpt b/ext/phar/tests/cache_list/frontcontroller16.phpt new file mode 100644 index 0000000000..10bebdccef --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller16.phpt @@ -0,0 +1,18 @@ +--TEST-- +Phar front controller mime type override, Phar::PHP [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller16.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller16.php +REQUEST_URI=/frontcontroller16.php/a.phps +PATH_INFO=/a.phps +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECT-- +hio1 + diff --git a/ext/phar/tests/cache_list/frontcontroller17.phpt b/ext/phar/tests/cache_list/frontcontroller17.phpt new file mode 100644 index 0000000000..35d3ae4e9c --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller17.phpt @@ -0,0 +1,18 @@ +--TEST-- +Phar front controller mime type unknown [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller17.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller17.php +REQUEST_URI=/frontcontroller17.php/fronk.gronk +PATH_INFO=/fronk.gronk +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: application/octet-stream +Content-length: 4 +--EXPECT-- +hio3 + diff --git a/ext/phar/tests/cache_list/frontcontroller18.phpt b/ext/phar/tests/cache_list/frontcontroller18.phpt new file mode 100644 index 0000000000..5e94bf6ff5 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller18.phpt @@ -0,0 +1,18 @@ +--TEST-- +Phar front controller $_SERVER munging failure [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller18.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller18.php +REQUEST_URI=/frontcontroller18.php/fronk.gronk +PATH_INFO=/fronk.gronk +--FILE_EXTERNAL-- +files/frontcontroller9.phar +--EXPECTF-- +Fatal error: Uncaught exception 'PharException' with message 'No values passed to Phar::mungServer(), expecting an array of any of these strings: PHP_SELF, REQUEST_URI, SCRIPT_FILENAME, SCRIPT_NAME' in %sfrontcontroller18.php:2 +Stack trace: +#0 %sfrontcontroller18.php(2): Phar::mungServer(Array) +#1 {main} + thrown in %sfrontcontroller18.php on line 2 diff --git a/ext/phar/tests/cache_list/frontcontroller19.phpt b/ext/phar/tests/cache_list/frontcontroller19.phpt new file mode 100644 index 0000000000..bed0b1df31 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller19.phpt @@ -0,0 +1,18 @@ +--TEST-- +Phar front controller $_SERVER munging failure 2 [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller19.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller19.php +REQUEST_URI=/frontcontroller19.php/ +PATH_INFO=/ +--FILE_EXTERNAL-- +files/frontcontroller10.phar +--EXPECTF-- +Fatal error: Uncaught exception 'PharException' with message 'Too many values passed to Phar::mungServer(), expecting an array of any of these strings: PHP_SELF, REQUEST_URI, SCRIPT_FILENAME, SCRIPT_NAME' in %sfrontcontroller19.php:2 +Stack trace: +#0 %sfrontcontroller19.php(2): Phar::mungServer(Array) +#1 {main} + thrown in %sfrontcontroller19.php on line 2 diff --git a/ext/phar/tests/cache_list/frontcontroller2.phpt b/ext/phar/tests/cache_list/frontcontroller2.phpt new file mode 100644 index 0000000000..67ccfc1e04 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller2.phpt @@ -0,0 +1,17 @@ +--TEST-- +Phar front controller PHP test [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list=frontcontroller2.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller2.php +REQUEST_URI=/frontcontroller2.php/a.php +PATH_INFO=/a.php +--FILE_EXTERNAL-- +files/frontcontroller.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECT-- +hio diff --git a/ext/phar/tests/cache_list/frontcontroller20.phpt b/ext/phar/tests/cache_list/frontcontroller20.phpt new file mode 100644 index 0000000000..bf333c773c --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller20.phpt @@ -0,0 +1,18 @@ +--TEST-- +Phar front controller $_SERVER munging failure 3 [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller20.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller20.php +REQUEST_URI=/frontcontroller20.php/ +PATH_INFO=/ +--FILE_EXTERNAL-- +files/frontcontroller11.phar +--EXPECTF-- +Fatal error: Uncaught exception 'PharException' with message 'Non-string value passed to Phar::mungServer(), expecting an array of any of these strings: PHP_SELF, REQUEST_URI, SCRIPT_FILENAME, SCRIPT_NAME' in %sfrontcontroller20.php:2 +Stack trace: +#0 %sfrontcontroller20.php(2): Phar::mungServer(Array) +#1 {main} + thrown in %sfrontcontroller20.php on line 2 diff --git a/ext/phar/tests/cache_list/frontcontroller21.phpt b/ext/phar/tests/cache_list/frontcontroller21.phpt new file mode 100644 index 0000000000..9ed315d19e --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller21.phpt @@ -0,0 +1,25 @@ +--TEST-- +Phar front controller $_SERVER munging success [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller21.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller21.php +REQUEST_URI=/frontcontroller21.php/index.php?test=hi +PATH_INFO=/index.php +QUERY_STRING=test=hi +--FILE_EXTERNAL-- +files/frontcontroller12.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +string(10) "/index.php" +string(10) "/index.php" +string(%d) "phar://%sfrontcontroller21.php/index.php" +string(18) "/index.php?test=hi" +string(32) "/frontcontroller21.php/index.php" +string(22) "/frontcontroller21.php" +string(%d) "%sfrontcontroller21.php" +string(40) "/frontcontroller21.php/index.php?test=hi" \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller22.phpt b/ext/phar/tests/cache_list/frontcontroller22.phpt new file mode 100644 index 0000000000..82a8389ad5 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller22.phpt @@ -0,0 +1,22 @@ +--TEST-- +Phar front controller include from cwd test 1 [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller22.phpt +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller22.php +REQUEST_URI=/frontcontroller22.php/index.php +PATH_INFO=/index.php +--FILE_EXTERNAL-- +files/frontcontroller13.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +string(4) "test" +string(12) "oof/test.php" + +Warning: include(./hi.php): failed to open stream: No such file or directory in phar://%s/oof/test.php on line %d + +Warning: include(): Failed opening './hi.php' for inclusion (include_path='%s') in phar://%soof/test.php on line %d \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller23.phpt b/ext/phar/tests/cache_list/frontcontroller23.phpt new file mode 100644 index 0000000000..3da9631dfb --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller23.phpt @@ -0,0 +1,18 @@ +--TEST-- +Phar front controller with generic action router test [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller23.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller23.php +REQUEST_URI=/frontcontroller23.php/hi/there +PATH_INFO=/hi/there +--FILE_EXTERNAL-- +files/frontcontroller14.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +string(9) "/hi/there" +string(%d) "phar://%sfrontcontroller23.php/html/index.php" \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller24.phpt b/ext/phar/tests/cache_list/frontcontroller24.phpt new file mode 100644 index 0000000000..561826bd78 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller24.phpt @@ -0,0 +1,17 @@ +--TEST-- +Phar front controller with custom 404 php script [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller24.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller24.php +REQUEST_URI=/frontcontroller24.php/unknown/file +PATH_INFO=/unknown/file +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +My 404 is rawesome \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller25.phpt b/ext/phar/tests/cache_list/frontcontroller25.phpt new file mode 100644 index 0000000000..a8779392b6 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller25.phpt @@ -0,0 +1,18 @@ +--TEST-- +Phar front controller with extra path_info [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller25.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller25.php +REQUEST_URI=/frontcontroller25.php/a1.phps/extra/stuff +PATH_INFO=/a1.phps/extra/stuff +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +string(42) "/frontcontroller25.php/a1.phps/extra/stuff" +string(12) "/extra/stuff" \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller26.phpt b/ext/phar/tests/cache_list/frontcontroller26.phpt new file mode 100644 index 0000000000..86a1c1444c --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller26.phpt @@ -0,0 +1,16 @@ +--TEST-- +Phar front controller with unknown extension mime type [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller26.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller26.php +REQUEST_URI=/frontcontroller26.php/unknown.ext +PATH_INFO=/unknown.ext +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: application/octet-stream +--EXPECTF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller27.php +REQUEST_URI=/frontcontroller27.php/noext +PATH_INFO=/noext +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: text/plain;charset=UTF-8 +--EXPECTF-- +hi \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller28.phpt b/ext/phar/tests/cache_list/frontcontroller28.phpt new file mode 100644 index 0000000000..80059a9da2 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller28.phpt @@ -0,0 +1,17 @@ +--TEST-- +Phar front controller with huge file [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller28.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller28.php +REQUEST_URI=/frontcontroller28.php/bigfile.txt +PATH_INFO=/bigfile.txt +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: text/plain;charset=UTF-8 +--EXPECT-- +aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa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aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa diff --git a/ext/phar/tests/cache_list/frontcontroller29.phpt b/ext/phar/tests/cache_list/frontcontroller29.phpt new file mode 100644 index 0000000000..1cd8f96f2d --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller29.phpt @@ -0,0 +1,17 @@ +--TEST-- +Phar front controller with fatal error in php file [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller29.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller29.php +REQUEST_URI=/frontcontroller29.php/fatalerror.phps +PATH_INFO=/fatalerror.phps +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECTF-- +Fatal error: Call to undefined function oopsie_daisy() in phar://%sfatalerror.phps on line 1 \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller3.phpt b/ext/phar/tests/cache_list/frontcontroller3.phpt new file mode 100644 index 0000000000..1c1b479881 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller3.phpt @@ -0,0 +1,20 @@ +--TEST-- +Phar front controller phps [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller3.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller3.php +REQUEST_URI=/frontcontroller3.php/a.phps +PATH_INFO=/a.phps +--FILE_EXTERNAL-- +files/frontcontroller.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECT-- + +<?php function hio(){} + + diff --git a/ext/phar/tests/cache_list/frontcontroller30.phpt b/ext/phar/tests/cache_list/frontcontroller30.phpt new file mode 100644 index 0000000000..5a63da874c --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller30.phpt @@ -0,0 +1,14 @@ +--TEST-- +Phar front controller with weird SCRIPT_NAME [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller30.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/huh? +REQUEST_URI=/huh? +--FILE_EXTERNAL-- +files/frontcontroller8.phar +--EXPECTF-- +oops did not run +%a \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller31.phpt b/ext/phar/tests/cache_list/frontcontroller31.phpt new file mode 100644 index 0000000000..9ef1221a28 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller31.phpt @@ -0,0 +1,16 @@ +--TEST-- +Phar front controller with invalid callback for rewrites [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller31.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller31.php +REQUEST_URI=/frontcontroller31.php +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--FILE_EXTERNAL-- +files/frontcontroller16.phar +--EXPECT-- +phar error: invalid rewrite callback \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller32.phpt b/ext/phar/tests/cache_list/frontcontroller32.phpt new file mode 100644 index 0000000000..59116907a5 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller32.phpt @@ -0,0 +1,16 @@ +--TEST-- +Phar front controller with valid callback that is not good [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller32.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller32.php +REQUEST_URI=/frontcontroller32.php +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--FILE_EXTERNAL-- +files/frontcontroller17.phar +--EXPECTF-- +%ahar error: failed to call rewrite callback \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller33.phpt b/ext/phar/tests/cache_list/frontcontroller33.phpt new file mode 100644 index 0000000000..9573854823 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller33.phpt @@ -0,0 +1,16 @@ +--TEST-- +Phar front controller with valid callback that does not return any value [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller33.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller33.php +REQUEST_URI=/frontcontroller33.php +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--FILE_EXTERNAL-- +files/frontcontroller18.phar +--EXPECTF-- +phar error: rewrite callback must return a string or false \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller34.phpt b/ext/phar/tests/cache_list/frontcontroller34.phpt new file mode 100644 index 0000000000..83c22f58f8 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller34.phpt @@ -0,0 +1,19 @@ +--TEST-- +Phar front controller with cwd [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller34.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller34.php +REQUEST_URI=/frontcontroller34.php/start/index.php +PATH_INFO=/start/index.php +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--FILE_EXTERNAL-- +files/frontcontroller19.phar +--EXPECT-- +start/index.php +start/another.php +another.php diff --git a/ext/phar/tests/cache_list/frontcontroller4.phpt b/ext/phar/tests/cache_list/frontcontroller4.phpt new file mode 100644 index 0000000000..5cf3682277 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller4.phpt @@ -0,0 +1,15 @@ +--TEST-- +Phar front controller index.php relocate (no /) [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller4.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller4.php +REQUEST_URI=/frontcontroller4.php +--FILE_EXTERNAL-- +files/frontcontroller.phar +--EXPECTHEADERS-- +Status: 301 Moved Permanently +Location: /frontcontroller4.php/index.php +--EXPECT-- diff --git a/ext/phar/tests/cache_list/frontcontroller5.phpt b/ext/phar/tests/cache_list/frontcontroller5.phpt new file mode 100644 index 0000000000..2c738d7bfb --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller5.phpt @@ -0,0 +1,16 @@ +--TEST-- +Phar front controller index.php relocate [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller5.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller5.php +REQUEST_URI=/frontcontroller5.php/ +PATH_INFO=/ +--FILE_EXTERNAL-- +files/frontcontroller.phar +--EXPECTHEADERS-- +Status: 301 Moved Permanently +Location: /frontcontroller5.php/index.php +--EXPECT-- diff --git a/ext/phar/tests/cache_list/frontcontroller6.phpt b/ext/phar/tests/cache_list/frontcontroller6.phpt new file mode 100644 index 0000000000..2480be4129 --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller6.phpt @@ -0,0 +1,23 @@ +--TEST-- +Phar front controller 404 [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller6.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller6.php +REQUEST_URI=/frontcontroller6.php/notfound.php +PATH_INFO=/notfound.php +--FILE_EXTERNAL-- +files/frontcontroller.phar +--EXPECTHEADERS-- +Status: 404 Not Found +--EXPECT-- + + + File Not Found + + +

404 - File /notfound.php Not Found

+ + \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller7.phpt b/ext/phar/tests/cache_list/frontcontroller7.phpt new file mode 100644 index 0000000000..a8a88a95fe --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller7.phpt @@ -0,0 +1,16 @@ +--TEST-- +Phar front controller alternate index file [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller7.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller7.php +REQUEST_URI=/frontcontroller7.php/ +PATH_INFO=/ +--FILE_EXTERNAL-- +files/frontcontroller2.phar +--EXPECTHEADERS-- +Status: 301 Moved Permanently +Location: /frontcontroller7.php/a.php +--EXPECT-- diff --git a/ext/phar/tests/cache_list/frontcontroller8.phpt b/ext/phar/tests/cache_list/frontcontroller8.phpt new file mode 100644 index 0000000000..bf9b390def --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller8.phpt @@ -0,0 +1,23 @@ +--TEST-- +Phar front controller no index file 404 [cache_list] +--INI-- +phar.cache_list={PWD}/frontcontroller8.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller8.php +REQUEST_URI=/frontcontroller8.php/ +PATH_INFO=/ +--FILE_EXTERNAL-- +files/frontcontroller3.phar +--EXPECTHEADERS-- +Status: 404 Not Found +--EXPECT-- + + + File Not Found + + +

404 - File /index.php Not Found

+ + \ No newline at end of file diff --git a/ext/phar/tests/cache_list/frontcontroller9.phpt b/ext/phar/tests/cache_list/frontcontroller9.phpt new file mode 100644 index 0000000000..1a8b9168cc --- /dev/null +++ b/ext/phar/tests/cache_list/frontcontroller9.phpt @@ -0,0 +1,20 @@ +--TEST-- +Phar front controller rewrite array [cache_list] +--INI-- +default_charset=UTF-8 +phar.cache_list={PWD}/frontcontroller9.php +--SKIPIF-- + +--ENV-- +SCRIPT_NAME=/frontcontroller9.php +REQUEST_URI=/frontcontroller9.php/hi +PATH_INFO=/hi +--FILE_EXTERNAL-- +files/frontcontroller3.phar +--EXPECTHEADERS-- +Content-type: text/html; charset=UTF-8 +--EXPECT-- + +<?php function hio(){} + + \ No newline at end of file -- 2.40.0