|
Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
|
Tests for Hash Fct. More...
#include <gtest/gtest.h>#include <hash-fct.H>#include <cstring>#include <random>#include <set>#include <string>#include <vector>Go to the source code of this file.
Classes | |
| class | HashTestEnvironment |
| class | HashConsistencyTest |
| class | HashEdgeCaseTest |
| class | HashDifferenceTest |
| class | HashVoidPtrTest |
| class | HashTemplateTest |
| class | HashDistributionTest |
| class | HashAvalancheTest |
Namespaces | |
| namespace | Aleph |
| Main namespace for Aleph-w library functions. | |
Functions | |
| void | Aleph::init_jsw () noexcept |
| TEST_F (HashConsistencyTest, AddHashConsistency) | |
| TEST_F (HashConsistencyTest, XorHashConsistency) | |
| TEST_F (HashConsistencyTest, RotHashConsistency) | |
| TEST_F (HashConsistencyTest, DjbHashConsistency) | |
| TEST_F (HashConsistencyTest, SaxHashConsistency) | |
| TEST_F (HashConsistencyTest, FnvHashConsistency) | |
| TEST_F (HashConsistencyTest, OatHashConsistency) | |
| TEST_F (HashConsistencyTest, JswHashConsistency) | |
| TEST_F (HashConsistencyTest, ElfHashConsistency) | |
| TEST_F (HashConsistencyTest, JenHashConsistency) | |
| TEST_F (HashConsistencyTest, SuperFastHashConsistency) | |
| TEST_F (HashConsistencyTest, Murmur3HashConsistency) | |
| TEST_F (HashConsistencyTest, DftHashFctConsistency) | |
| TEST_F (HashEdgeCaseTest, EmptyStringHash) | |
| TEST_F (HashEdgeCaseTest, SingleCharHash) | |
| TEST_F (HashEdgeCaseTest, LargeStringHash) | |
| TEST_F (HashEdgeCaseTest, BinaryDataWithNulls) | |
| TEST_F (HashDifferenceTest, DifferentStringsDifferentHashes) | |
| TEST_F (HashDifferenceTest, DifferentIntsDifferentHashes) | |
| TEST_F (HashDifferenceTest, DifferentSeedsDifferentHashes) | |
| TEST_F (HashVoidPtrTest, IntArrayHash) | |
| TEST_F (HashVoidPtrTest, StructHash) | |
| TEST_F (HashTemplateTest, IntTemplateHash) | |
| TEST_F (HashTemplateTest, DoubleTemplateHash) | |
| TEST_F (HashTemplateTest, LongLongTemplateHash) | |
| TEST (PairHashTest, PairDftHashFct) | |
| TEST (PairHashTest, PairSndHashFct) | |
| TEST_F (HashDistributionTest, FnvHashUniqueness) | |
| TEST_F (HashDistributionTest, OatHashUniqueness) | |
| TEST_F (HashDistributionTest, SuperFastHashUniqueness) | |
| TEST_F (HashDistributionTest, JenHashUniqueness) | |
| TEST_F (HashDistributionTest, Murmur3HashUniqueness) | |
| TEST_F (HashDistributionTest, DftHashFctUniqueness) | |
| TEST_F (HashAvalancheTest, SingleBitChangeJenkins) | |
| TEST_F (HashAvalancheTest, SingleBitChangeMurmur3) | |
| TEST_F (HashAvalancheTest, SingleBitChangeOat) | |
| TEST (HashKnownValuesTest, AddHashKnownValue) | |
| TEST (HashKnownValuesTest, XorHashKnownValue) | |
| TEST (HashKnownValuesTest, FnvHashStartValue) | |
| TEST (SeededHashTest, JenHashWithDefaultSeed) | |
| TEST (SeededHashTest, DftHashFctWithSeed) | |
| TEST (HashTypeSafetyTest, SignedUnsignedConsistency) | |
| TEST (HashTypeSafetyTest, ConstCharPtrAndStringConsistency) | |
| TEST (HashPerformanceTest, LargeDataHashing) | |
| TEST (HashPerformanceTest, ManySmallHashes) | |
Variables | |
| testing::Environment *const | hash_env |
Tests for Hash Fct.
Exhaustive test suite for hash functions in hash-fct.H.
Tests cover:
Definition in file hash_fct_test.cc.
| TEST | ( | HashKnownValuesTest | , |
| AddHashKnownValue | |||
| ) |
Definition at line 722 of file hash_fct_test.cc.
References Aleph::add_hash(), and Aleph::maps().
| TEST | ( | HashKnownValuesTest | , |
| FnvHashStartValue | |||
| ) |
Definition at line 734 of file hash_fct_test.cc.
References Aleph::fnv_hash(), and Aleph::maps().
| TEST | ( | HashKnownValuesTest | , |
| XorHashKnownValue | |||
| ) |
Definition at line 728 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::xor_hash().
| TEST | ( | HashPerformanceTest | , |
| LargeDataHashing | |||
| ) |
Definition at line 794 of file hash_fct_test.cc.
References Aleph::fnv_hash(), Aleph::maps(), Aleph::murmur3hash(), Aleph::oat_hash(), and Aleph::SuperFastHash().
| TEST | ( | HashPerformanceTest | , |
| ManySmallHashes | |||
| ) |
Definition at line 811 of file hash_fct_test.cc.
References Aleph::fnv_hash(), Aleph::maps(), and Aleph::sum().
| TEST | ( | HashTypeSafetyTest | , |
| ConstCharPtrAndStringConsistency | |||
| ) |
Definition at line 775 of file hash_fct_test.cc.
References Aleph::djb_hash(), Aleph::fnv_hash(), Aleph::maps(), Aleph::oat_hash(), Aleph::sax_hash(), and Aleph::SuperFastHash().
| TEST | ( | HashTypeSafetyTest | , |
| SignedUnsignedConsistency | |||
| ) |
Definition at line 764 of file hash_fct_test.cc.
References Aleph::fnv_hash(), and Aleph::maps().
| TEST | ( | PairHashTest | , |
| PairDftHashFct | |||
| ) |
Definition at line 524 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::pair_dft_hash_fct().
| TEST | ( | PairHashTest | , |
| PairSndHashFct | |||
| ) |
Definition at line 540 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::pair_snd_hash_fct().
| TEST | ( | SeededHashTest | , |
| DftHashFctWithSeed | |||
| ) |
Definition at line 752 of file hash_fct_test.cc.
References Aleph::dft_hash_fct(), and Aleph::maps().
| TEST | ( | SeededHashTest | , |
| JenHashWithDefaultSeed | |||
| ) |
Definition at line 744 of file hash_fct_test.cc.
References Aleph::Default_Hash_Seed, Aleph::jen_hash(), and Aleph::maps().
| TEST_F | ( | HashAvalancheTest | , |
| SingleBitChangeJenkins | |||
| ) |
Definition at line 674 of file hash_fct_test.cc.
References Aleph::jen_hash(), and Aleph::maps().
| TEST_F | ( | HashAvalancheTest | , |
| SingleBitChangeMurmur3 | |||
| ) |
Definition at line 691 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::murmur3hash().
| TEST_F | ( | HashAvalancheTest | , |
| SingleBitChangeOat | |||
| ) |
Definition at line 705 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::oat_hash().
| TEST_F | ( | HashConsistencyTest | , |
| AddHashConsistency | |||
| ) |
Definition at line 93 of file hash_fct_test.cc.
References Aleph::add_hash(), and Aleph::maps().
| TEST_F | ( | HashConsistencyTest | , |
| DftHashFctConsistency | |||
| ) |
Definition at line 267 of file hash_fct_test.cc.
References Aleph::dft_hash_fct(), and Aleph::maps().
| TEST_F | ( | HashConsistencyTest | , |
| DjbHashConsistency | |||
| ) |
Definition at line 139 of file hash_fct_test.cc.
References Aleph::djb_hash(), and Aleph::maps().
| TEST_F | ( | HashConsistencyTest | , |
| ElfHashConsistency | |||
| ) |
Definition at line 209 of file hash_fct_test.cc.
References Aleph::elf_hash(), and Aleph::maps().
| TEST_F | ( | HashConsistencyTest | , |
| FnvHashConsistency | |||
| ) |
Definition at line 167 of file hash_fct_test.cc.
References Aleph::fnv_hash(), and Aleph::maps().
| TEST_F | ( | HashConsistencyTest | , |
| JenHashConsistency | |||
| ) |
Definition at line 223 of file hash_fct_test.cc.
References Aleph::jen_hash(), and Aleph::maps().
| TEST_F | ( | HashConsistencyTest | , |
| JswHashConsistency | |||
| ) |
Definition at line 195 of file hash_fct_test.cc.
References Aleph::jsw_hash(), and Aleph::maps().
| TEST_F | ( | HashConsistencyTest | , |
| Murmur3HashConsistency | |||
| ) |
Definition at line 255 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::murmur3hash().
| TEST_F | ( | HashConsistencyTest | , |
| OatHashConsistency | |||
| ) |
Definition at line 181 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::oat_hash().
| TEST_F | ( | HashConsistencyTest | , |
| RotHashConsistency | |||
| ) |
Definition at line 125 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::rot_hash().
| TEST_F | ( | HashConsistencyTest | , |
| SaxHashConsistency | |||
| ) |
Definition at line 153 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::sax_hash().
| TEST_F | ( | HashConsistencyTest | , |
| SuperFastHashConsistency | |||
| ) |
Definition at line 241 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::SuperFastHash().
| TEST_F | ( | HashConsistencyTest | , |
| XorHashConsistency | |||
| ) |
Definition at line 109 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::xor_hash().
| TEST_F | ( | HashDifferenceTest | , |
| DifferentIntsDifferentHashes | |||
| ) |
Definition at line 391 of file hash_fct_test.cc.
References Aleph::djb_hash(), Aleph::fnv_hash(), Aleph::maps(), Aleph::oat_hash(), and Aleph::SuperFastHash().
| TEST_F | ( | HashDifferenceTest | , |
| DifferentSeedsDifferentHashes | |||
| ) |
Definition at line 405 of file hash_fct_test.cc.
References Aleph::jen_hash(), Aleph::maps(), and Aleph::murmur3hash().
| TEST_F | ( | HashDifferenceTest | , |
| DifferentStringsDifferentHashes | |||
| ) |
Definition at line 369 of file hash_fct_test.cc.
References Aleph::djb_hash(), Aleph::elf_hash(), Aleph::fnv_hash(), Aleph::jsw_hash(), Aleph::maps(), Aleph::oat_hash(), Aleph::sax_hash(), and Aleph::SuperFastHash().
| TEST_F | ( | HashDistributionTest | , |
| DftHashFctUniqueness | |||
| ) |
Definition at line 643 of file hash_fct_test.cc.
References Aleph::dft_hash_fct(), and Aleph::maps().
| TEST_F | ( | HashDistributionTest | , |
| FnvHashUniqueness | |||
| ) |
Definition at line 588 of file hash_fct_test.cc.
References Aleph::fnv_hash(), and Aleph::maps().
| TEST_F | ( | HashDistributionTest | , |
| JenHashUniqueness | |||
| ) |
Definition at line 621 of file hash_fct_test.cc.
References Aleph::jen_hash(), and Aleph::maps().
| TEST_F | ( | HashDistributionTest | , |
| Murmur3HashUniqueness | |||
| ) |
Definition at line 632 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::murmur3hash().
| TEST_F | ( | HashDistributionTest | , |
| OatHashUniqueness | |||
| ) |
Definition at line 599 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::oat_hash().
| TEST_F | ( | HashDistributionTest | , |
| SuperFastHashUniqueness | |||
| ) |
Definition at line 610 of file hash_fct_test.cc.
References Aleph::maps(), and Aleph::SuperFastHash().
| TEST_F | ( | HashEdgeCaseTest | , |
| BinaryDataWithNulls | |||
| ) |
Definition at line 350 of file hash_fct_test.cc.
References Aleph::add_hash(), Aleph::fnv_hash(), Aleph::jen_hash(), Aleph::maps(), Aleph::oat_hash(), and Aleph::SuperFastHash().
| TEST_F | ( | HashEdgeCaseTest | , |
| EmptyStringHash | |||
| ) |
Definition at line 295 of file hash_fct_test.cc.
References Aleph::add_hash(), Aleph::djb_hash(), Aleph::elf_hash(), Aleph::fnv_hash(), Aleph::jsw_hash(), Aleph::maps(), Aleph::oat_hash(), Aleph::rot_hash(), Aleph::sax_hash(), Aleph::SuperFastHash(), and Aleph::xor_hash().
| TEST_F | ( | HashEdgeCaseTest | , |
| LargeStringHash | |||
| ) |
Definition at line 330 of file hash_fct_test.cc.
References Aleph::fnv_hash(), Aleph::maps(), Aleph::murmur3hash(), Aleph::oat_hash(), and Aleph::SuperFastHash().
| TEST_F | ( | HashEdgeCaseTest | , |
| SingleCharHash | |||
| ) |
Definition at line 310 of file hash_fct_test.cc.
References Aleph::add_hash(), Aleph::djb_hash(), Aleph::elf_hash(), Aleph::fnv_hash(), Aleph::jsw_hash(), Aleph::maps(), Aleph::oat_hash(), Aleph::rot_hash(), Aleph::sax_hash(), Aleph::SuperFastHash(), and Aleph::xor_hash().
| TEST_F | ( | HashTemplateTest | , |
| DoubleTemplateHash | |||
| ) |
Definition at line 496 of file hash_fct_test.cc.
References Aleph::fnv_hash(), Aleph::maps(), and Aleph::oat_hash().
| TEST_F | ( | HashTemplateTest | , |
| IntTemplateHash | |||
| ) |
Definition at line 482 of file hash_fct_test.cc.
References Aleph::add_hash(), Aleph::fnv_hash(), and Aleph::maps().
| TEST_F | ( | HashTemplateTest | , |
| LongLongTemplateHash | |||
| ) |
Definition at line 509 of file hash_fct_test.cc.
References Aleph::fnv_hash(), Aleph::maps(), and Aleph::SuperFastHash().
| TEST_F | ( | HashVoidPtrTest | , |
| IntArrayHash | |||
| ) |
Definition at line 432 of file hash_fct_test.cc.
References Aleph::add_hash(), Aleph::Default_Hash_Seed, Aleph::fnv_hash(), Aleph::jen_hash(), Aleph::maps(), Aleph::oat_hash(), and Aleph::SuperFastHash().
| TEST_F | ( | HashVoidPtrTest | , |
| StructHash | |||
| ) |
Definition at line 450 of file hash_fct_test.cc.
References Aleph::fnv_hash(), Aleph::maps(), Aleph::oat_hash(), and Aleph::SuperFastHash().
| testing::Environment* const hash_env |
Definition at line 78 of file hash_fct_test.cc.