List of usage examples for java.lang Object Object
@HotSpotIntrinsicCandidate
public Object()
From source file:org.openspaces.eviction.test.ClassSpecificOrderTest.java
protected void assertMemoryShortageTest() { Assert.assertEquals("not only gold medals remain in space", gigaSpace.count(new Object()), gigaSpace.count(new GoldMedal())); }
From source file:com.redhat.lightblue.metadata.types.DateTypeTest.java
@Test public void testCompareV2Null() { assertEquals(dateType.compare(new Object(), null), 1); }
From source file:org.jimsey.projects.turbine.condenser.web.IndicatorController.java
@RequestMapping("/{market}/{symbol}/{name}/{date}") public String getIndicatorsAfter(@PathVariable String market, @PathVariable String symbol, @PathVariable String name, @PathVariable Long date) throws JsonProcessingException { logger.info("getIndicatorsAfter({}, {}, {}, {})", market, symbol, name, date); List<IndicatorJson> indicators = elasticsearchServiceImpl .findIndicatorsByMarketAndSymbolAndNameAndDateGreaterThan(market, symbol, name, date); // TODO can do this with java 8 lambdas? Object dto = new Object() { @JsonProperty("indicators") List<IndicatorJson> indicatorz = indicators; };// w w w. j a v a2s. co m return json.writeValueAsString(dto); }
From source file:com.redhat.lightblue.metadata.types.BigDecimalTypeTest.java
@Test(expected = Error.class) public void testCastOtherTest() { bigDecimalType.cast(new Object()); }
From source file:com.trk.aboutme.facebook.internal.FileLruCache.java
public FileLruCache(Context context, String tag, Limits limits) { this.tag = tag; this.limits = limits; this.directory = new File(context.getCacheDir(), tag); this.lock = new Object(); // Ensure the cache dir exists this.directory.mkdirs(); // Remove any stale partially-written files from a previous run BufferFile.deleteAll(this.directory); }
From source file:com.godaddy.logging.logstash.LogstashTests.java
@Test public void test_logback_json_log() throws IOException { Object toLog = new Object() { String horse = "NEIGH"; Object inner = new Object() { String car = "VROOM"; };/*from ww w . jav a 2s . com*/ }; logger.with(toLog).info("YO"); Map<String, Object> output = getJson(); assertEquals(output.get("horse"), "NEIGH"); assertEquals(((LinkedHashMap) output.get("inner")).get("car"), "VROOM"); assertEquals(output.get("level"), "INFO"); assertEquals(output.get("customMessage"), "YO"); }
From source file:main.ExtTSVImporterTest.java
/** * Test the number of total targets for all reports. *//* ww w . j a v a2 s . c om*/ @Test public void testNumberTargets() { System.out.println("Running test " + this.getClass().getSimpleName() + "." + new Object() { }.getClass().getEnclosingMethod().getName()); int targets = 0; for (int i = 0; i < reports.size(); i++) { targets = targets + reports.get(i).getDataRowNumber(); } assertEquals(28, targets); }
From source file:com.codebullets.sagalib.processing.SagaExecutionTaskTest.java
@Before public void init() { saga = mock(Saga.class, withSettings().extraInterfaces(NeedContext.class)); state = mock(SagaState.class); timeoutManager = mock(TimeoutManager.class); storage = mock(StateStorage.class); instanceResolver = mock(InstanceResolver.class); invoker = mock(HandlerInvoker.class); sagaInstanceInfo = mock(SagaInstanceInfo.class); module = mock(SagaModule.class); interceptor = mock(SagaLifetimeInterceptor.class); theMessage = new Object(); when(saga.state()).thenReturn(state); when(sagaInstanceInfo.getSaga()).thenReturn(saga); when(instanceResolver.resolve(argThat(isA(LookupContext.class)))) .thenReturn(Lists.newArrayList(sagaInstanceInfo)); Provider<CurrentExecutionContext> contextProvider = mockExecutionContext(); SagaEnvironment env = SagaEnvironment.create(timeoutManager, storage, contextProvider, Sets.newHashSet(module), Sets.newHashSet(interceptor), instanceResolver); sut = new SagaExecutionTask(env, invoker, theMessage, new HashMap<String, Object>(), null); }
From source file:main.BasicTSVImporterTest.java
/** * Test the number of total targets for all reports. *///from w w w . j a va2s . c om @Test public void testNumberTargets() { System.out.println("Running test " + this.getClass().getSimpleName() + "." + new Object() { }.getClass().getEnclosingMethod().getName()); int targets = 0; for (int i = 0; i < reports.size(); i++) { targets = targets + reports.get(i).getDataRowNumber(); } assertEquals(29, targets); }
From source file:jp.terasoluna.fw.beans.jxpath.DynamicPointerFactoryExTest.java
/** * testCreateNodePointerQname02() <br> * <br>//w w w . jav a2s . c om * () <br> * A <br> * <br> * () name:not null<br> * () bean:new Object()<br> * () locale:Locale("ja")<br> * () bi.isDynamic():false<br> * <br> * () NodePointer:null<br> * <br> * Map?????Null? <br> * @throws Exception ????? */ @Test public void testCreateNodePointerQname02() throws Exception { // ?? DynamicPointerFactoryEx factory = new DynamicPointerFactoryEx(); QName qName = new QName("name"); Object bean = new Object(); Locale locale = new Locale("ja"); // assertNull(factory.createNodePointer(qName, bean, locale)); }