Facebook ???????????????
???????????? ???????[ 2012/2/28 13:41:43 ] ????????
??????Quora???и??????????????facebook???????????????????????????????????????????????????????????????
????????Facebook??Steven Grimm????????????????????????????????????????????? ??
????PHP?????????д??????????PHPUnit??????????????Щ?????????Χ??????????ж??????????????????????????????????????????????Щ????PHPUnit????????????????????е???????????Щ????????Щ?????豸???????????(?????????????)??????????????Щ??????????????????????????????????????????????Щ?????????????????????????????????????????????????????diff??????????review???????????????????и???????????檔
??????????????????Waitir(???Waitir?????UI?????????????)?????????????????????????????Щ???????????????????????????????????????棬???磺?????X??????Y????Y???/?????????Z????????????????????????????????????????(??Щ???????????????Щ??????????????????????????Щ???????????????????е??????????????????????????????????????????????????)
?????Щ???watir????????????????????????Щ???????????????Щ??????????waitir????????????????Щ???????????button???????????????????????????????ζ?????????????????????????????????????????????????
???????????????JSSpec (???JavaScript?????????)????ЩJavaScript????????????????????????????
????????????????????????????????????????????????????????????Щ?????????????????????????????????????Boost??JUnit??????(???Boost?????C++/JUnit?????Java???????);?????????Щ????????????????????????磬????????????????????????????????build????????????C++??????????????????????????????????????????????????????????????????/Build????????????Щ?????????build???????????????????????в????????????????????????????洢????????????????????????
HipHop(???HipHop for PHP??Facebook??PHP???)?????????????????????HipHop????????????л???PHPUnit???????????С????е???Щ?????????????????PHP?????????????????????????????PHP??????????;
????Facebook????????????????洢??????????????????????????????????????????????????????????Χ?????????????????????(???磬?????????????????????????????????????????????????????????????????????????)?????????UI??????????? ???/?????????????????????????????????????????????????????????
??????????????????????????????????????????????????????п???????????(??Facebook???з???????????????????????????????????????????????????????????????????????????????????????)?????????????????????????????????????????????Facebook????????????????????????????????????
??????????????????????????????????????????????Щ???????????????????????????????????????????PHPUnit??Watir??Facebook?????????????????е???????????????????д??????????????????????Щ???????????????????????????Щ??????????????????С?
????Facebook????????????????????????Σ????????????????????????е?????????
??????? 2012/2/27
???????????
????What kind of automated testing does Facebook do? How do they make sure they aren??t breaking things in their weekly pushes?
????Steven Grimm?? 2005-2012
????We do several kinds of testing. Some specifics:
????For our PHP code?? we have a suite of a few thousand test classes using the PHPUnit framework. They range in complexity from simple true unit tests to large-scale integration tests that hit our production backend services. The PHPUnit tests are run both by developers as part of their workflow and continuously by an automated test runner on dedicated hardware. Our developer tools automatically use code coverage data to run tests that cover the outstanding edits in a developer sandbox?? and a report of test results is automatically included in our code review tool when a patch is submitted for review.
For browser-based testing of our Web code?? we use the Watir framework. We have Watir tests covering a range of the site??s functionality?? particularly focused on privacy?there are tons of ??user X posts item Y and it should/shouldn??t be visible to user Z?? tests at the browser level. (Those privacy rules are?? of course?? also tested at a lower level?? but the privacy implementation being rock-solid is a critical priority and warrants redundant test coverage.)
In addition to the fully automated Watir tests?? we have semi-automated tests that use Watir so humans can avoid the drudgery of filling out form fields and pressing buttons to get through UI flows?? but can still examine what??s going on and validate that things look reasonable.
??????

???·???
App??С????H5?????????????????Щ??
2024/9/11 15:34:34?????????????????????????
2024/9/10 11:13:49P-One ???????????????????????????????????????
2024/9/10 10:14:12???????????????????????????
2024/9/9 18:04:26??????????????????
2023/3/23 14:23:39???д?ò??????????
2023/3/22 16:17:39????????????????????Щ??
2022/6/14 16:14:27??????????????????????????
2021/10/18 15:37:44