<commit_before>package com.hazelcast.monitor.impl;

import com.eclipsesource.json.JsonObject;
import com.hazelcast.cache.CacheStatistics;
import com.hazelcast.test.HazelcastParallelClassRunner;
import com.hazelcast.test.annotation.QuickTest;
import org.junit.Test;
import org.junit.experimental.categories.Category;
import org.junit.runner.RunWith;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;

@RunWith(HazelcastParallelClassRunner.class)
@Category(QuickTest.class)
public class LocalCacheStatsImplTest {

    private LocalCacheStatsImpl localCacheStats = new LocalCacheStatsImpl();

    @Test
    public void testDefaultConstructor() {
        assertEquals(0, localCacheStats.getCacheHits());
        assertEquals(0, localCacheStats.getCacheHitPercentage(), 0.0001);
        assertEquals(0, localCacheStats.getCacheMisses());
        assertEquals(0, localCacheStats.getCacheMissPercentage(), 0.0001);
        assertEquals(0, localCacheStats.getCachePuts());
        assertEquals(0, localCacheStats.getCacheGets());
        assertEquals(0, localCacheStats.getCacheRemovals());
        assertEquals(0, localCacheStats.getCacheEvictions());
        assertEquals(0, localCacheStats.getAverageGetTime(), 0.0001);
        assertEquals(0, localCacheStats.getAveragePutTime(), 0.0001);
        assertEquals(0, localCacheStats.getAverageRemoveTime(), 0.0001);
        assertEquals(0, localCacheStats.getCreationTime());
        assertNotNull(localCacheStats.toString());
    }

    @Test
    public void testSerialization() {
        CacheStatistics cacheStatistics = new CacheStatistics() {
            @Override
            public long getCacheHits() {
                return 127;
            }

            @Override
            public float getCacheHitPercentage() {
                return 12.5f;<commit_msg>Removed unnecessary member variable in LocalCacheStatsImplTest.<commit_after>package com.hazelcast.monitor.impl;

import com.eclipsesource.json.JsonObject;
import com.hazelcast.cache.CacheStatistics;
import com.hazelcast.test.HazelcastParallelClassRunner;
import com.hazelcast.test.annotation.QuickTest;
import org.junit.Test;
import org.junit.experimental.categories.Category;
import org.junit.runner.RunWith;

import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
import static org.junit.Assert.assertTrue;

@RunWith(HazelcastParallelClassRunner.class)
@Category(QuickTest.class)
public class LocalCacheStatsImplTest {

    @Test
    public void testDefaultConstructor() {
        LocalCacheStatsImpl localCacheStats = new LocalCacheStatsImpl();

        assertEquals(0, localCacheStats.getCacheHits());
        assertEquals(0, localCacheStats.getCacheHitPercentage(), 0.0001);
        assertEquals(0, localCacheStats.getCacheMisses());
        assertEquals(0, localCacheStats.getCacheMissPercentage(), 0.0001);
        assertEquals(0, localCacheStats.getCachePuts());
        assertEquals(0, localCacheStats.getCacheGets());
        assertEquals(0, localCacheStats.getCacheRemovals());
        assertEquals(0, localCacheStats.getCacheEvictions());
        assertEquals(0, localCacheStats.getAverageGetTime(), 0.0001);
        assertEquals(0, localCacheStats.getAveragePutTime(), 0.0001);
        assertEquals(0, localCacheStats.getAverageRemoveTime(), 0.0001);
        assertEquals(0, localCacheStats.getCreationTime());
        assertNotNull(localCacheStats.toString());
    }

    @Test
    public void testSerialization() {
        CacheStatistics cacheStatistics = new CacheStatistics() {
            @Override
            public long getCacheHits() {
                return 127;
            }

            @Override
            public float getCacheHitPercentage() {
                return 12.5f;
{'fraction_non_alphanumeric': 0.09723670490093848, 'fraction_numerical': 0.022419186652763295, 'mean_word_length': 3.881679389312977, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6024200', 'n_tokens_mistral': 1080, 'n_tokens_neox': 1014, 'n_words': 181}