我想知道,你们怎么在CakePHP进行单元测试?你如何在项目中加入测试?你测试的项目的哪些部分?您如何确定哪些部件可以进行单元测试?你们还能在截止日期前完成工作吗?
我想知道,是否有关于何时使用会话和 cookie 的指南或最佳实践?什么应该和什么不应该存储在其中?谢谢!
我正在阅读实用程序员,而我正在阅读作者建议我们每年学习一门新语言的部分.我现在是一名PHP开发人员,我想知道,接下来我应该学习什么?
我正在寻找一种能帮助我提高技能并帮助我完成日常工作的语言.有用的东西.
有什么建议?
[编辑]很棒的答案家伙!谢谢.我还在考虑你的答案,我倾向于研究Python或者你们建议的功能性的prgoramming语言(也许是Lisp).
嗨我从书中得到了代码:
public class Container {
Map<String, Object> components;
public Container() {
components = new HashMap<String, Object>();
Properties properties = new Properties();
try {
properties.load(new FileInputStream("components.properties"));
for (Map.Entry entry : properties.entrySet()) {
String key = (String) entry.getKey();
String value = (String) entry.getValue();
processEntry(key, value);
}
} catch (Exception ex) {
throw new RuntimeException();
}
}
private void processEntry(String key, String value) throws Exception {
String parts[] = key.split("\\.");
if (parts.length == 1) {
Object component = Class.forName(value).newInstance();
components.put(parts[0], component);
} else …Run Code Online (Sandbox Code Playgroud)