lucene-solr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rm...@apache.org
Subject svn commit: r922996 - in /lucene/solr/branches/solr: ./ contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/ lib/ src/common/org/apache/solr/common/ src/common/org/apache/solr/common/util/ src/maven/ src/solrj/org/ src/solrj/org/...
Date Sun, 14 Mar 2010 22:58:18 GMT
Author: rmuir
Date: Sun Mar 14 22:58:18 2010
New Revision: 922996

URL: http://svn.apache.org/viewvc?rev=922996&view=rev
Log:
merge up to trunk rev 922991

Modified:
    lucene/solr/branches/solr/   (props changed)
    lucene/solr/branches/solr/CHANGES.txt
    lucene/solr/branches/solr/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestEvaluatorBag.java
    lucene/solr/branches/solr/lib/commons-httpclient-3.1.jar   (props changed)
    lucene/solr/branches/solr/lib/jcl-over-slf4j-1.5.5.jar   (props changed)
    lucene/solr/branches/solr/src/common/org/apache/solr/common/   (props changed)
    lucene/solr/branches/solr/src/common/org/apache/solr/common/util/JavaBinCodec.java   (props
changed)
    lucene/solr/branches/solr/src/maven/solr-core-pom.xml.template   (props changed)
    lucene/solr/branches/solr/src/maven/solr-solrj-pom.xml.template   (props changed)
    lucene/solr/branches/solr/src/solrj/org/   (props changed)
    lucene/solr/branches/solr/src/solrj/org/apache/solr/client/solrj/impl/StreamingUpdateSolrServer.java
  (props changed)
    lucene/solr/branches/solr/src/test/org/apache/solr/client/   (props changed)
    lucene/solr/branches/solr/src/webapp/src/org/apache/solr/client/solrj/embedded/   (props
changed)

Propchange: lucene/solr/branches/solr/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -2,3 +2,4 @@
 /lucene/java/branches/lucene_2_9/solr:817269-818600,825998,829134,829881,831036,896850,909334
 /lucene/java/branches/lucene_2_9_back_compat_tests/solr:818601-821336
 /lucene/java/branches/lucene_3_0/solr:880793,896906
+/lucene/solr/trunk:922950-922991

Modified: lucene/solr/branches/solr/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/solr/branches/solr/CHANGES.txt?rev=922996&r1=922995&r2=922996&view=diff
==============================================================================
--- lucene/solr/branches/solr/CHANGES.txt (original)
+++ lucene/solr/branches/solr/CHANGES.txt Sun Mar 14 22:58:18 2010
@@ -261,6 +261,9 @@ Other Changes
 * SOLR-1776: DismaxQParser and ExtendedDismaxQParser now use the schema.xml
   "defaultSearchField" as the default value for the "qf" param instead of failing
   with an error when "qf" is not specified.  (hossman)
+
+* SOLR-1821: Fix TimeZone-dependent test failure in TestEvaluatorBag.
+  (Chris Male via rmuir)
   
 Build
 ----------------------

Modified: lucene/solr/branches/solr/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestEvaluatorBag.java
URL: http://svn.apache.org/viewvc/lucene/solr/branches/solr/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestEvaluatorBag.java?rev=922996&r1=922995&r2=922996&view=diff
==============================================================================
--- lucene/solr/branches/solr/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestEvaluatorBag.java
(original)
+++ lucene/solr/branches/solr/contrib/dataimporthandler/src/test/java/org/apache/solr/handler/dataimport/TestEvaluatorBag.java
Sun Mar 14 22:58:18 2010
@@ -123,15 +123,20 @@ public class TestEvaluatorBag {
     ContextImpl context = new ContextImpl(null, resolver, null, Context.FULL_DUMP, Collections.EMPTY_MAP,
null, null);
     Context.CURRENT_CONTEXT.set(context);
     try {
-      long time = System.currentTimeMillis();
-      assertEquals(new SimpleDateFormat("yyyy-MM-dd HH:mm").format(new Date(time - 2*86400*1000)),
+      Calendar calendar = new GregorianCalendar();
+      calendar.add(Calendar.DAY_OF_YEAR, -2);
+
+      assertEquals(new SimpleDateFormat("yyyy-MM-dd HH:mm").format(calendar.getTime()),
               dateFormatEval.evaluate("'NOW-2DAYS','yyyy-MM-dd HH:mm'", Context.CURRENT_CONTEXT.get()));
 
+      calendar = new GregorianCalendar();
+      Date date = calendar.getTime();
+      
       Map<String, Object> map = new HashMap<String, Object>();
-      map.put("key", new Date(time));
+      map.put("key", date);
       resolver.addNamespace("A", map);
 
-      assertEquals(new SimpleDateFormat("yyyy-MM-dd HH:mm").format(new Date(time)),
+      assertEquals(new SimpleDateFormat("yyyy-MM-dd HH:mm").format(date),
               dateFormatEval.evaluate("A.key, 'yyyy-MM-dd HH:mm'", Context.CURRENT_CONTEXT.get()));
     } finally {
       Context.CURRENT_CONTEXT.remove();

Propchange: lucene/solr/branches/solr/lib/commons-httpclient-3.1.jar
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/lib/commons-httpclient-3.1.jar:922950-922991

Propchange: lucene/solr/branches/solr/lib/jcl-over-slf4j-1.5.5.jar
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/lib/jcl-over-slf4j-1.5.5.jar:922950-922991

Propchange: lucene/solr/branches/solr/src/common/org/apache/solr/common/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/src/common/org/apache/solr/common:922950-922991

Propchange: lucene/solr/branches/solr/src/common/org/apache/solr/common/util/JavaBinCodec.java
            ('svn:mergeinfo' removed)

Propchange: lucene/solr/branches/solr/src/maven/solr-core-pom.xml.template
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/src/maven/solr-core-pom.xml.template:922950-922991

Propchange: lucene/solr/branches/solr/src/maven/solr-solrj-pom.xml.template
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/src/maven/solr-solrj-pom.xml.template:922950-922991

Propchange: lucene/solr/branches/solr/src/solrj/org/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/src/solrj/org:922950-922991

Propchange: lucene/solr/branches/solr/src/solrj/org/apache/solr/client/solrj/impl/StreamingUpdateSolrServer.java
            ('svn:mergeinfo' removed)

Propchange: lucene/solr/branches/solr/src/test/org/apache/solr/client/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/src/test/org/apache/solr/client:922950-922991

Propchange: lucene/solr/branches/solr/src/webapp/src/org/apache/solr/client/solrj/embedded/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Sun Mar 14 22:58:18 2010
@@ -0,0 +1 @@
+/lucene/solr/trunk/src/webapp/src/org/apache/solr/client/solrj/embedded:922950-922991



Mime
View raw message