Commit b0aa22d3 authored by Liang Ding's avatar Liang Ding

修复单元测试

parent 1124b892
...@@ -406,6 +406,7 @@ public final class SoloServletListener extends AbstractServletListener { ...@@ -406,6 +406,7 @@ public final class SoloServletListener extends AbstractServletListener {
final OtherConsole otherConsole = beanManager.getReference(OtherConsole.class); final OtherConsole otherConsole = beanManager.getReference(OtherConsole.class);
DispatcherServlet.delete("/console/archive/unused", otherConsole::removeUnusedArchives); DispatcherServlet.delete("/console/archive/unused", otherConsole::removeUnusedArchives);
DispatcherServlet.delete("/console/tag/unused", otherConsole::removeUnusedTags);
final UserConsole userConsole = beanManager.getReference(UserConsole.class); final UserConsole userConsole = beanManager.getReference(UserConsole.class);
DispatcherServlet.put("/console/user/", userConsole::updateUser); DispatcherServlet.put("/console/user/", userConsole::updateUser);
......
...@@ -23,7 +23,7 @@ ...@@ -23,7 +23,7 @@
<html> <html>
<head> <head>
<#if !blogTitle??> <#if !blogTitle??>
<#assign blogTitle = welcomeToSoloLabel> <#assign blogTitle = "Solo">
</#if> </#if>
<@head title="${title} - ${blogTitle}"> <@head title="${title} - ${blogTitle}">
<link type="text/css" rel="stylesheet" <link type="text/css" rel="stylesheet"
......
...@@ -145,7 +145,7 @@ public class MockHttpServletRequest implements HttpServletRequest { ...@@ -145,7 +145,7 @@ public class MockHttpServletRequest implements HttpServletRequest {
@Override @Override
public String getQueryString() { public String getQueryString() {
throw new UnsupportedOperationException("Not supported yet."); return "";
} }
@Override @Override
......
...@@ -49,7 +49,7 @@ public class IndexProcessorTestCase extends AbstractTestCase { ...@@ -49,7 +49,7 @@ public class IndexProcessorTestCase extends AbstractTestCase {
mockDispatcherServletService(request, response); mockDispatcherServletService(request, response);
final String content = response.body(); final String content = response.body();
Assert.assertTrue(StringUtils.contains(content, "<title>欢迎使用!</title>")); Assert.assertTrue(StringUtils.contains(content, "<title>欢迎使用! - Solo</title>"));
} }
/** /**
......
...@@ -58,6 +58,6 @@ public class TagProcessorTestCase extends AbstractTestCase { ...@@ -58,6 +58,6 @@ public class TagProcessorTestCase extends AbstractTestCase {
mockDispatcherServletService(request, response); mockDispatcherServletService(request, response);
final String content = response.body(); final String content = response.body();
Assert.assertTrue(StringUtils.contains(content, "<title>Solo - Solo 的个人博客</title>")); Assert.assertTrue(StringUtils.contains(content, "<title>Solo 标签 - Solo 的个人博客</title>"));
} }
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment