《Cracking the Coding Interview》——第12章:测试——题目4
2014-04-25 00:35
题目:没有专门的测试工具,你要如何对一个网页进行压力测试?
解法:拼手速,拼电脑数量呗。快捷键+复制粘贴网址,狂搞一番。话说回来,有脚本语言的情况下,直接写个脚本来模拟大量的访问行为肯定是更合理的,手速再快比不过程序。没有工具时,应该想着如何制造工具,而不是赤手空拳去搞。
代码:
// 12.4 How would you load test a webpage, if you're not allowed to use any test tools?
// Answer:
// As far as what I've learned, load testing is a testing method which puts the system under limited resources and exposes it to excessive pressure.
// 1. Browser side:
// 1.a. Use a PC with low configuration, but it must sufficient to see the webpage.
// 1.b. Use various browsers to see their different performances.
// 1.c. Open multiple instances of this webpage, see if it fails to respond.
// 2. Server side:
// 2.a. Deploy the web server on a server(maybe a PC) with low configuration.
// 2.b. Try to visit it with multiple clients(many users at the same time).
// 2.c. If the system includes some storage, try to fill it up with POST or GET actions on the webpage.
int main()
{
return ;
}
《Cracking the Coding Interview》——第12章:测试——题目4的更多相关文章
- Cracking the coding interview 第一章问题及解答
Cracking the coding interview 第一章问题及解答 不管是不是要挪地方,面试题具有很好的联系代码总用,参加新工作的半年里,做的大多是探索性的工作,反而代码写得少了,不高兴,最 ...
- 《Cracking the Coding Interview》读书笔记
<Cracking the Coding Interview>是适合硅谷技术面试的一本面试指南,因为题目分类清晰,风格比较靠谱,所以广受推崇. 以下是我的读书笔记,基本都是每章的课后习题解 ...
- Cracking the coding interview
写在开头 最近忙于论文的开题等工作,还有阿里的实习笔试,被虐的还行,说还行是因为自己的水平或者说是自己准备的还没有达到他们所需要人才的水平,所以就想找一本面试的书<Cracking the co ...
- Cracking the coding interview目录及资料收集
前言 <Cracking the coding interview>是一本被许多人极力推荐的程序员面试书籍, 详情可见:http://www.careercup.com/book. 第六版 ...
- Cracking the Coding Interview(Trees and Graphs)
Cracking the Coding Interview(Trees and Graphs) 树和图的训练平时相对很少,还是要加强训练一些树和图的基础算法.自己对树节点的设计应该不是很合理,多多少少 ...
- Cracking the Coding Interview(Stacks and Queues)
Cracking the Coding Interview(Stacks and Queues) 1.Describe how you could use a single array to impl ...
- 《Cracking the Coding Interview》——第12章:测试——题目6
2014-04-25 00:53 题目:你要如何测试一个分布式银行系统的ATM机? 解法:ATM是Automatic Teller Machine,取钱的.我想了半天,没找到什么很清晰的思路,也许是因 ...
- 《Cracking the Coding Interview》——第12章:测试——题目5·
2014-04-25 00:41 题目:怎么测试一支笔?(Pen?您老说的是钢笔?) 解法:这种简约而不简单的题目,实在是面试官最喜欢,面试者最头疼的类型了.面试官可以只花三秒,以一种灰常高贵冷艳的语 ...
- 《Cracking the Coding Interview》——第12章:测试——题目3
2014-04-24 23:28 题目:玩象棋游戏,你要设计一个bool型的方法来检测一个棋子能否移动到指定位置. 解法:不同的棋子有不同的移动规则,那么应该采取棋子基类实现接口,各个棋子子类来实现的 ...
随机推荐
- 立体最短路径,广搜(POJ2251)
题目链接:http://poj.org/problem?id=2251 参考了一下大神们的解法.也有用深搜的.然而,之前不久看到一句话,最短路径——BFS. 参考:http://blog.csdn.n ...
- 模拟网页的浏览Stack(POJ1028)
题目链接:http://poj.org/problem?id=1028 注意: 1.用两个栈来模拟,一个用来存可以返回的,一个用来存可以前进的. 2.visit方法,就要将可以前进的栈清空. 3.ba ...
- set方法的使用
<div id='root'> <div v-for='(item,key,index) of userInfo'> {{item}}--{{key}}--{{index}} ...
- 表单(三):select
选择框的value属性 <select name='location' id='selLocation'> <option value='Sunnyvale,Ca'>Sunny ...
- laravel 去掉index.php伪静态
1,首先,让apache服务器支持rewrite 可以在apache配置文件中定义rewrite规则,是全局的,无论哪个应用都实用 //httpd.config Listen 80 RewriteEn ...
- 3、SpringBoot+MybatisPlus整合-------代码生成器
<dependency> <groupId>org.projectlombok</groupId> <artifactId>lombok</art ...
- Java 单词 day seven
Constructor Constructor Constructor Constructor Constructor Constructor Constructor Constructor Cons ...
- BFS算法入门--POJ3984
迷宫问题–POJ3984 Time Limit: 1000MS Memory Limit: 65536K Total Submissions: 22008 Accepted: 12848 Descri ...
- Delphi的Edit控件中只能输入数字且只能输入一个小数点
使用这种功能必须使用 OnKeyPress 事件,该事件是在窗体中获得键盘输入的焦点,并且在用户按键时发生.OnKeyPress 事件中有个重要参数:Key.Key 参数为Char 型,它能够获得用户 ...
- org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in class path resource [spring/applicationContext-service.xml]: Cannot resolve refer
<!-- aop --> <aop:config> <aop:pointcut expression="execution(* com.zsn.Service. ...