Browse Source

Makefile updated for debian/ubuntu and for symbol problems (tests updated and README updated as well). Currently untested on ANY other system.

debian_default_test
parent
commit
d668967388
67 changed files with 253 additions and 168 deletions
  1. +18
    -17
      test/Makefile
  2. +111
    -28
      test/README.md
  3. +1
    -1
      test/gen_test_skel.py
  4. +1
    -1
      test/gtest_firstpass.py
  5. +1
    -1
      test/src/AppleMailTest.cc
  6. +1
    -1
      test/src/BCCTest.cc
  7. +1
    -1
      test/src/BlacklistAcceptNewKeyTest.cc
  8. +1
    -1
      test/src/BlacklistTest.cc
  9. +1
    -1
      test/src/CaseAndDotAddressTest.cc
  10. +1
    -1
      test/src/CheckRenewedExpiredKeyTrustStatusTest.cc
  11. +1
    -1
      test/src/CrashdumpTest.cc
  12. +1
    -1
      test/src/DecorateTest.cc
  13. +1
    -1
      test/src/DecryptAttachPrivateKeyTrustedTest.cc
  14. +1
    -1
      test/src/DecryptAttachPrivateKeyUntrustedTest.cc
  15. +1
    -1
      test/src/DeleteKeyTest.cc
  16. +1
    -1
      test/src/EncryptAttachPrivateKeyTest.cc
  17. +1
    -1
      test/src/EncryptForIdentityTest.cc
  18. +1
    -1
      test/src/EncryptMissingPrivateKeyTest.cc
  19. +1
    -1
      test/src/Engine358Test.cc
  20. +1
    -1
      test/src/Engine463Test.cc
  21. +1
    -1
      test/src/EnterLeaveDeviceGroupTest.cc
  22. +1
    -1
      test/src/ExpiredSubkeyTest.cc
  23. +1
    -1
      test/src/ExportKeyTest.cc
  24. +1
    -1
      test/src/ExternalRevokeTest.cc
  25. +1
    -1
      test/src/GetKeyRatingForUserTest.cc
  26. +1
    -1
      test/src/HeaderKeyImportTest.cc
  27. +1
    -1
      test/src/I18nTest.cc
  28. +1
    -1
      test/src/IOS1664Test.cc
  29. +1
    -1
      test/src/KeyAttachmentTest.cc
  30. +1
    -1
      test/src/KeyResetMessageTest.cc
  31. +1
    -1
      test/src/KeyeditTest.cc
  32. +1
    -1
      test/src/KeyringImportTest.cc
  33. +1
    -1
      test/src/LeastColorGroupTest.cc
  34. +1
    -1
      test/src/LeastCommonDenomColorTest.cc
  35. +1
    -1
      test/src/LiteralFilenameTest.cc
  36. +1
    -1
      test/src/LookupTest.cc
  37. +1
    -1
      test/src/LotsOfKeysTest.cc
  38. +1
    -1
      test/src/MapAsn1Test.cc
  39. +1
    -1
      test/src/Message2_1Test.cc
  40. +1
    -1
      test/src/MessageApiTest.cc
  41. +1
    -1
      test/src/MessageNullFromTest.cc
  42. +1
    -1
      test/src/MessageTwoPointOhTest.cc
  43. +1
    -1
      test/src/MimeTest.cc
  44. +1
    -1
      test/src/NoOwnIdentWritesOnDecryptTest.cc
  45. +1
    -1
      test/src/OwnIdentitiesRetrieveTest.cc
  46. +1
    -1
      test/src/OwnKeysRetrieveTest.cc
  47. +1
    -1
      test/src/PepSubjectReceivedTest.cc
  48. +1
    -1
      test/src/PgpBinaryTest.cc
  49. +1
    -1
      test/src/PgpListKeysTest.cc
  50. +1
    -1
      test/src/ReencryptPlusExtraKeysTest.cc
  51. +1
    -1
      test/src/RevocationTest.cc
  52. +1
    -1
      test/src/RevokeRegenAttachTest.cc
  53. +1
    -1
      test/src/SenderFPRTest.cc
  54. +1
    -1
      test/src/SequenceTest.cc
  55. +1
    -1
      test/src/SignOnlyTest.cc
  56. +1
    -1
      test/src/SimpleBodyNotAltTest.cc
  57. +1
    -1
      test/src/SubkeyRatingEvalTest.cc
  58. +1
    -1
      test/src/SyncTest.cc
  59. +1
    -1
      test/src/ThreadSpamTest.cc
  60. +1
    -1
      test/src/TrustManipulationTest.cc
  61. +1
    -1
      test/src/TrustwordsTest.cc
  62. +1
    -1
      test/src/URIAddressTest.cc
  63. +1
    -1
      test/src/UpdateIdAndMyselfTest.cc
  64. +1
    -1
      test/src/UserIDAliasTest.cc
  65. +1
    -1
      test/src/UserIdCollisionTest.cc
  66. +1
    -1
      test/src/VerifyTest.cc
  67. +60
    -59
      test/src/test_util.cc

+ 18
- 17
test/Makefile View File

@ -5,12 +5,12 @@
HERE:=$(CURDIR)
# Presumably can be changed in local.conf by putting this here?
GTEST_DIR:=googletest/googletest
GTEST_PL_DIR:=googletest/gtest-parallel
GTEST_INC_DIR:=$(GTEST_DIR)/include
GTEST_SRC_DIR:=/usr/src/gtest
GTEST_INC_DIR:=$(GTEST_SRC_DIR)/include
GTEST_PL:=$(HOME)/src/gtest-parallel/gtest_parallel.py
include ../Makefile.conf
include ../Makefile.conf # This should import changed values for the above from
# local.conf
SRCS:=$(wildcard src/*.cc) $(wildcard src/*/*.cc)
OBJS:=$(addsuffix .o,$(basename $(SRCS)))
@ -18,7 +18,15 @@ DEPS:=$(OBJS:.o=.d)
LDFLAGS+= -L../asn.1 -L../src $(ETPAN_LIB) $(CPPUNIT_LIB)
TARGET:=EngineTests
TARGET:=EngineTests
GTEST_SUITE_SYM:=test_suite_name
ifeq ($(shell grep -c $(GTEST_SUITE_SYM) $(GTEST_SRC_DIR)/src/gtest.cc),0)
GTEST_SUITE_SYM=test_case_name
endif
CXXFLAGS+= -DGTEST_SUITE_SYM=$(GTEST_SUITE_SYM)
ifeq ($(OPENPGP),GPG)
LDFLAGS+= $(GPGME_LIB)
@ -99,22 +107,15 @@ all:
%.d: %.cc
$(CXX) -MM $(CPPFLAGS) $(CXXFLAGS) $< | sed -e 's,\($*\)\.o[ :]*,\1.o $@: ,g' > $@
$(TARGET): $(OBJS) gtest-all.o gtest_main.o
# $(LINK.cc) $(OBJS) $(LOADLIBES) $(LDLIBS) -o $@
${CXX} ${LDFLAGS} -L${PREFIX}/lib -o $@ $^ -lpEpEngine $(LDLIBS)
$(TARGET): $(OBJS)
${CXX} ${LDFLAGS} -L${PREFIX}/lib -o $@ $^ -lpEpEngine -lgtest -lgtest_main -lsequoia_openpgp_ffi $(LDLIBS)
gtest-all.o: $(GTEST_DIR)/src/gtest-all.cc
${CXX} ${CXXFLAGS} $(CPPFLAGS) -I$(GTEST_DIR) $(CXXFLAGS) -isystem $(GTEST_DIR)/include -o $@ -c $<
gtest_main.o: $(GTEST_DIR)/src/gtest_main.cc
${CXX} ${CXXFLAGS} $(CPPFLAGS) -I$(GTEST_DIR) $(CXXFLAGS) -isystem $(GTEST_DIR)/include -o $@ -c $<
test: all
$(TEST_CMD_PFX) $(TEST_DEBUGGER) python3 $(GTEST_PL_DIR)/gtest_parallel.py ./$(TARGET)
$(RM) -rf ./pEp_test_home/*
$(TEST_CMD_PFX) $(TEST_DEBUGGER) python3 $(GTEST_PL) ./$(TARGET)
clean:
$(RM) $(TARGET) $(TARGET).o $(TARGET).d $(OBJS) $(notdir $(basename $(OBJS))) $(DEPS)
$(RM) gtest_main.o gtest-all.o
$(RM) -rf ./pEp_test_home/*
# If only the goal 'clean' is given, do not generate and include the '%.d' files.¬
ifneq ($(MAKECMDGOALS),clean)


+ 111
- 28
test/README.md View File

@ -1,62 +1,145 @@
# Building the Engine Test Suite
# Building and Running the Tests for the p≡p Engine
Work in progress... Currently have the debian build/run instructions in.
## Caveat, before you begin
Right now, the engine tests only function on \*nix-like systems (including MacOS). (Conversion to Windows will require, at the very least, looking at some of the file-handling code.) If you want to fix this, start by looking in Engine.cc in the test/src directory!
Right now, the engine tests only function on \*nix-like systems (including
MacOS).
*(Conversion to Windows will require, at the very least, looking at some of the
file-handling code. If you want to fix this, start by looking in Engine.cc
in the test/src directory!)*
## Requirements
In addition to the engine requirements, you will need:
* cmake
* python3
* `cmake` `python3` `git` (for getting the `gtest-parallel` repository, unless
* you grab the tarball from somewhere)
## Building the prerequisites
The Engine test suite now requires (at least) two additional pieces to run:
* `googletest`
* `gtest-parallel`
How this proceeds depends on your platform and whether or not you use a packaged
distribution.
These instructions do this with `cmake`. If you can manage it with `bazel`
instead, more power to you ;)
### Installing `googletest`
#### Packaged distributions
This is the currently preferred way to do this, because everyone was doing it
anyway and who am I to judge?
##### Debian and Ubuntu (and derivatives)
## Preparing to build
Thanks to Erik Smistad for this starting point (condensed from [Getting Started
with Google Test On
Ubuntu](https://www.eriksmistad.no/getting-started-with-google-test-on-ubuntu/)):
The Engine test suite now requires (at least) two additional pieces to run - **googletest** and **gtest-parallel**. You will note that I give specific instructions about where to put these, because that is what I have tried and tested. That does NOT mean other things won’t work; I simply haven’t tried them. So without further ado…
1. Install the packages `cmake` and `libgtest-dev` from the repository. This
will install the gtest source files to `/usr/src/gtest`. You'll still need to
compile the code and link the library files to be able to use them.
### googletest
2. Compile the source files:
```
cd /usr/src/gtest
sudo cmake CMakeLists.txt
sudo make
```
**googletest** is an XUnit testing framework we are now using in place of cpptest. Unlike a lot of other testing frameworks, it’s recommended that you compile and link the test code directly within your project. These instructions do with with **cmake**. If you can manage it with **bazel** instead, more power to you ;)
3. Copy/symlink the libraries to the library location of your choice (here,
it's `/usr/lib`, hence the `sudo`, but as long as it's in your library path,
it shouldn't matter where you stick it):
```
sudo cp *.a /usr/lib
```
So. To get things started.
##### MacOS
In the directory of your choice (default, if you don’t want to change **local.conf** - specifically **GTEST\_DIR** - is the test directory (this one, presumably)):
I am totally guessing for now - this is a placeholder - that
macports gtest install will do the same. Will need to find the directories this
goes in. Guessing `/opt/local/src`.
1. git clone https://github.com/google/googletest.git
2. cd googletest
3. cmake .
4. make
#### Downloading and compiling the source yourself
(Note that this hasn’t been tested in other directories, so I am presuming the Makefile works as is, but I could be wrong)
For now, don't.
### gtest-parallel
Or do, and document it for me.
### Again, in the directory of your choice (if you want to use the Makefile out of the box, you should, while still in the googletest directory, do the following):
If you were using the git repo and it was working before, please follow the
instructions above for Debian/Ubuntu, only with your source repository in mind
instead of `/usr/src`, and pay attention to the variables you'll need to set in
`local.conf` for the Makefile - they are different from before.
It should work, but I haven't tested it yet.
1. git clone https://github.com/google/gtest-parallel.git
2. If using a different directory, please change **GTEST\_PL\_DIR** to indicate where **gtest-parallel.py** is located.
### Installing `gtest-parallel`
Pick a source directory and put your `gtest-parallel` source there
(e.g. via `git clone https://github.com/google/gtest-parallel.git`).
We'll deal more with this when preparing to compile the test suite.
## Building the test suite
### `Makefile` and `local.conf`
So `local.conf` in the top-level engine directory is where we stick all of the
Makefile overrides. The test Makefile contains some defaults for relevant
variables here, but if you need to override them, please either create or modify
`local.conf` in the top-level engine directory as needed. The relevant variables
are:
* `GTEST_SRC_DIR`: This is the directory where the gtest source you compiled
above is located (defaults to `/usr/src/gtest`)
* `GTEST_INC_DIR`: This is where the include files for gtest are located
(defaults to `$(GTEST_SRC_DIR)/include`)
* `GTEST_PL`: This is the full path to the *python file* for `gtest_parallel`
(default presumes you cloned it under `src` in your home directory, i.e. it is
`$(HOME)/src/gtest-parallel/gtest_parallel.py`)
### Building
Presuming the above works, then from the top test directory, simply run make.
# Running the Engine Test Suite
## Running the test suite
## To simply run the test suite and see what tests fail...
### To simply run the test suite and see what tests fail...
Do one of:
1. make test OR
2. python3 \<path to gtest-parallel.py\> ./EngineTests
1. `make test` OR
2. `python3 <path to gtest-parallel.py> ./EngineTests`
### To run individual test suites, especially for debugging purposes
Note that for some test suites, this will, if something goes dreadfully wrong,
mean that one test's failure may pollute another test. This generally means you
have found a dastardly bug in the engine, but it can also be a test issue.
## To run individual test suites, especially for debugging purposes
*Caveat lector*.
1. To run sequentially, IN THE SAME PROCESS: ./EngineTests --gtest_filter=TestSuiteName* (for example, for DeleteKeyTest: ./EngineTests DeleteKeyTest*)
2. To debug the same: lldb ./EngineTests -- --gtest_filter=TestSuiteName*
3. To run sequentially IN DIFFERENT PROCESSES: (FIXME - is this really the case?)
1. To run sequentially, *in the same process*: `./EngineTests
--gtest_filter=TestSuiteName*` (for example, for `DeleteKeyTest`:
`./EngineTests DeleteKeyTest*`)
2. To debug the same with lldb: `lldb ./EngineTests -- --gtest_filter=TestSuiteName*`
3. To debug with gdb: `gdb --args ./EngineTests --gtest_filter=TestSuiteName*`
### To run and/or debug individual test cases
1. To run: `./EngineTests --gtest_filter=TestSuiteName.test_function_name`
(for example, for `check_delete_single_pubkey` in `DeleteKeyTest`:
`./EngineTests DeleteKeyTest.check_delete_single_pubkey`)
2. To debug the same with lldb:
`lldb ./EngineTests -- --gtest_filter=TestSuiteName.test_function_name`
3. To debug with gdb:
`gdb --args ./EngineTests --gtest_filter=TestSuiteName.test_function_name`
# Creating new tests
Script next on the agenda...

+ 1
- 1
test/gen_test_skel.py View File

@ -47,7 +47,7 @@ newfile.write(tb(3) + "// You can remove any or all of the following functions i
newfile.write(tb(3) + "// is empty.\n")
newfile.write(tb(3) + test_suite + "() {\n")
newfile.write(tb(4) + "// You can do set-up work for each test here.\n")
newfile.write(tb(4) + "test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();\n")
newfile.write(tb(4) + "test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();\n")
newfile.write(tb(4) + "test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();\n")
newfile.write(tb(4) + "test_path = get_main_test_home_dir() + \"/\" + test_suite_name + \"/\" + test_name;\n")
newfile.write(tb(3) + "}\n\n")


+ 1
- 1
test/gtest_firstpass.py View File

@ -78,7 +78,7 @@ for filename in os.listdir("src"):
newfile.write(tb(3) + "// is empty.\n")
newfile.write(tb(3) + "" + modline + "() {\n")
newfile.write(tb(4) + "// You can do set-up work for each test here.\n")
newfile.write(tb(4) + "test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();\n")
newfile.write(tb(4) + "test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();\n")
newfile.write(tb(4) + "test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();\n")
newfile.write(tb(4) + "test_path = get_main_test_home_dir() + \"/\" + test_suite_name + \"/\" + test_name;\n")
newfile.write(tb(3) + "}\n\n")


+ 1
- 1
test/src/AppleMailTest.cc View File

@ -37,7 +37,7 @@ namespace {
// is empty.
AppleMailTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/BCCTest.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
BCCTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/BlacklistAcceptNewKeyTest.cc View File

@ -34,7 +34,7 @@ namespace {
// is empty.
BlacklistAcceptNewKeyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/BlacklistTest.cc View File

@ -48,7 +48,7 @@ namespace {
// is empty.
BlacklistTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/CaseAndDotAddressTest.cc View File

@ -32,7 +32,7 @@ namespace {
// is empty.
CaseAndDotAddressTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/CheckRenewedExpiredKeyTrustStatusTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
CheckRenewedExpiredKeyTrustStatusTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/CrashdumpTest.cc View File

@ -27,7 +27,7 @@ namespace {
// is empty.
CrashdumpTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/DecorateTest.cc View File

@ -33,7 +33,7 @@ namespace {
// is empty.
DecorateTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/DecryptAttachPrivateKeyTrustedTest.cc View File

@ -35,7 +35,7 @@ namespace {
// is empty.
DecryptAttachPrivateKeyTrustedTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/DecryptAttachPrivateKeyUntrustedTest.cc View File

@ -33,7 +33,7 @@ namespace {
// is empty.
DecryptAttachPrivateKeyUntrustedTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/DeleteKeyTest.cc View File

@ -43,7 +43,7 @@ namespace {
// is empty.
DeleteKeyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/EncryptAttachPrivateKeyTest.cc View File

@ -33,7 +33,7 @@ namespace {
// is empty.
EncryptAttachPrivateKeyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/EncryptForIdentityTest.cc View File

@ -35,7 +35,7 @@ namespace {
// is empty.
EncryptForIdentityTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/EncryptMissingPrivateKeyTest.cc View File

@ -38,7 +38,7 @@ namespace {
// is empty.
EncryptMissingPrivateKeyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/Engine358Test.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
Engine358Test() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/Engine463Test.cc View File

@ -30,7 +30,7 @@ namespace {
// is empty.
Engine463Test() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/EnterLeaveDeviceGroupTest.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
EnterLeaveDeviceGroupTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/ExpiredSubkeyTest.cc View File

@ -28,7 +28,7 @@ namespace {
// is empty.
ExpiredSubkeyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/ExportKeyTest.cc View File

@ -30,7 +30,7 @@ namespace {
// is empty.
ExportKeyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/ExternalRevokeTest.cc View File

@ -35,7 +35,7 @@ namespace {
// is empty.
ExternalRevokeTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/GetKeyRatingForUserTest.cc View File

@ -30,7 +30,7 @@ namespace {
// is empty.
GetKeyRatingForUserTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/HeaderKeyImportTest.cc View File

@ -32,7 +32,7 @@ namespace {
// is empty.
HeaderKeyImportTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/I18nTest.cc View File

@ -28,7 +28,7 @@ namespace {
// is empty.
I18nTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/IOS1664Test.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
IOS1664Test() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/KeyAttachmentTest.cc View File

@ -33,7 +33,7 @@ namespace {
// is empty.
KeyAttachmentTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/KeyResetMessageTest.cc View File

@ -53,7 +53,7 @@ class KeyResetMessageTest : public ::testing::Test {
// is empty.
KeyResetMessageTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/KeyeditTest.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
KeyeditTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/KeyringImportTest.cc View File

@ -34,7 +34,7 @@ namespace {
// is empty.
KeyringImportTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/LeastColorGroupTest.cc View File

@ -34,7 +34,7 @@ namespace {
// is empty.
LeastColorGroupTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/LeastCommonDenomColorTest.cc View File

@ -34,7 +34,7 @@ namespace {
// is empty.
LeastCommonDenomColorTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/LiteralFilenameTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
LiteralFilenameTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/LookupTest.cc View File

@ -33,7 +33,7 @@ namespace {
// is empty.
LookupTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/LotsOfKeysTest.cc View File

@ -144,7 +144,7 @@ namespace {
// is empty.
LotsOfKeysTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/MapAsn1Test.cc View File

@ -30,7 +30,7 @@ namespace {
// is empty.
MapAsn1Test() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/Message2_1Test.cc View File

@ -28,7 +28,7 @@ namespace {
// is empty.
Message2_1Test() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/MessageApiTest.cc View File

@ -34,7 +34,7 @@ namespace {
// is empty.
MessageApiTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/MessageNullFromTest.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
MessageNullFromTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/MessageTwoPointOhTest.cc View File

@ -35,7 +35,7 @@ namespace {
// is empty.
MessageTwoPointOhTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/MimeTest.cc View File

@ -33,7 +33,7 @@ namespace {
// is empty.
MimeTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/NoOwnIdentWritesOnDecryptTest.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
NoOwnIdentWritesOnDecryptTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
_to_decrypt = NULL;


+ 1
- 1
test/src/OwnIdentitiesRetrieveTest.cc View File

@ -28,7 +28,7 @@ namespace {
// is empty.
OwnIdentitiesRetrieveTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/OwnKeysRetrieveTest.cc View File

@ -28,7 +28,7 @@ namespace {
// is empty.
OwnKeysRetrieveTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/PepSubjectReceivedTest.cc View File

@ -34,7 +34,7 @@ namespace {
// is empty.
PepSubjectReceivedTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/PgpBinaryTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
PgpBinaryTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/PgpListKeysTest.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
PgpListKeysTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/ReencryptPlusExtraKeysTest.cc View File

@ -34,7 +34,7 @@ namespace {
// is empty.
ReencryptPlusExtraKeysTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/RevocationTest.cc View File

@ -33,7 +33,7 @@ namespace {
// is empty.
RevocationTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/RevokeRegenAttachTest.cc View File

@ -37,7 +37,7 @@ namespace {
// is empty.
RevokeRegenAttachTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/SenderFPRTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
SenderFPRTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/SequenceTest.cc View File

@ -28,7 +28,7 @@ namespace {
// is empty.
SequenceTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/SignOnlyTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
SignOnlyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/SimpleBodyNotAltTest.cc View File

@ -31,7 +31,7 @@ namespace {
// is empty.
SimpleBodyNotAltTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/SubkeyRatingEvalTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
SubkeyRatingEvalTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/SyncTest.cc View File

@ -162,7 +162,7 @@ namespace {
// is empty.
SyncTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/ThreadSpamTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
ThreadSpamTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/TrustManipulationTest.cc View File

@ -32,7 +32,7 @@ namespace {
// is empty.
TrustManipulationTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/TrustwordsTest.cc View File

@ -27,7 +27,7 @@ namespace {
// is empty.
TrustwordsTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/URIAddressTest.cc View File

@ -30,7 +30,7 @@ namespace {
// is empty.
URIAddressTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/UpdateIdAndMyselfTest.cc View File

@ -35,7 +35,7 @@ namespace {
// is empty.
UpdateIdAndMyselfTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/UserIDAliasTest.cc View File

@ -32,7 +32,7 @@ namespace {
// is empty.
UserIDAliasTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/UserIdCollisionTest.cc View File

@ -110,7 +110,7 @@ namespace {
// is empty.
UserIdCollisionTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 1
- 1
test/src/VerifyTest.cc View File

@ -29,7 +29,7 @@ namespace {
// is empty.
VerifyTest() {
// You can do set-up work for each test here.
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->test_suite_name();
test_suite_name = ::testing::UnitTest::GetInstance()->current_test_info()->GTEST_SUITE_SYM();
test_name = ::testing::UnitTest::GetInstance()->current_test_info()->name();
test_path = get_main_test_home_dir() + "/" + test_suite_name + "/" + test_name;
}


+ 60
- 59
test/src/test_util.cc View File

@ -9,6 +9,7 @@
#include "keymanagement.h"
#include <fstream>
#include <algorithm>
#include <sstream>
#include <iostream>
#include <stdexcept>
@ -42,18 +43,18 @@ std::string random_string( size_t length )
}
std::string get_main_test_home_dir() {
size_t BUF_MAX_PATHLEN = 4097;
size_t BUF_MAX_PATHLEN = 4097;
char buf[BUF_MAX_PATHLEN];// Linux max path size...
if (_main_test_home_dir.empty()) {
string curr_wd = getcwd(buf, BUF_MAX_PATHLEN);
if (curr_wd.empty())
throw std::runtime_error("Error grabbing current working directory");
throw std::runtime_error("Error grabbing current working directory");
_main_test_home_dir = curr_wd + "/pEp_test_home";
}
return _main_test_home_dir;
return _main_test_home_dir;
}
PEP_STATUS read_file_and_import_key(PEP_SESSION session, const char* fname) {
@ -61,7 +62,7 @@ PEP_STATUS read_file_and_import_key(PEP_SESSION session, const char* fname) {
PEP_STATUS status = (key.empty() ? PEP_KEY_NOT_FOUND : PEP_STATUS_OK);
if (status == PEP_STATUS_OK)
status = import_key(session, key.c_str(), key.size(), NULL);
return status;
return status;
}
PEP_STATUS set_up_ident_from_scratch(PEP_SESSION session,
@ -77,31 +78,31 @@ PEP_STATUS set_up_ident_from_scratch(PEP_SESSION session,
return status;
else
status = PEP_STATUS_OK;
pEp_identity* ident = new_identity(address, fpr, user_id, username);
if (is_priv && fpr) {
status = set_own_key(session, ident, fpr);
if (status == PEP_STATUS_OK)
status = myself(session, ident);
}
else
else
status = update_identity(session, ident);
if (status != PEP_STATUS_OK)
goto pep_free;
if (!ident || !ident->fpr) {
status = PEP_CANNOT_FIND_IDENTITY;
goto pep_free;
}
if (ret_ident)
*ret_ident = ident;
pep_free:
if (!ret_ident)
free_identity(ident);
return status;
return status;
}
@ -117,11 +118,11 @@ char* str_to_lower(const char* str) {
if (str_len == 0)
return strdup("");
int i;
char* retval = (char*) calloc(1, str_len + 1);
for (i = 0; i < str_len; i++) {
retval[i] = tolower(str[i]);
}
}
return retval;
}
@ -134,7 +135,7 @@ bool _streq(const char* str1, const char* str2) {
}
if (!str2)
return false;
return (strcmp(str1, str2) == 0);
}
@ -161,7 +162,7 @@ std::string slurp(const std::string& filename)
{
throw std::runtime_error("Cannot read file \"" + filename + "\"! ");
}
std::stringstream sstr;
sstr << input.rdbuf();
return sstr.str();
@ -174,7 +175,7 @@ void dump_out(const char* filename, const char* outdata)
{
throw std::runtime_error("Cannot open output file!");
}
outfile << outdata;
outfile.close();
}
@ -312,9 +313,9 @@ const char* tl_status_string(PEP_STATUS status) {
case PEP_OUT_OF_MEMORY:
return "PEP_OUT_OF_MEMORY";
case PEP_UNKNOWN_ERROR:
return "PEP_UNKNOWN_ERROR";
return "PEP_UNKNOWN_ERROR";
default:
return "PEP_STATUS_OMGWTFBBQ - This means you're using a status the test lib doesn't know about!";
}
}
@ -453,9 +454,9 @@ bool slurp_message_and_import_key(PEP_SESSION session, const char* message_fname
return ok;
}
int util_delete_filepath(const char *filepath,
const struct stat *file_stat,
int ftw_info,
int util_delete_filepath(const char *filepath,
const struct stat *file_stat,
int ftw_info,
struct FTW * ftw_struct) {
int retval = 0;
switch (ftw_info) {
@ -465,11 +466,11 @@ int util_delete_filepath(const char *filepath,
case FTW_F:
case FTW_SLN:
retval = unlink(filepath);
break;
break;
default:
retval = -1;
}
return retval;
}
@ -482,9 +483,9 @@ static PEP_STATUS update_identity_recip_list(PEP_SESSION session,
if (!session)
return PEP_UNKNOWN_ERROR;
identity_list* id_list_ptr = NULL;
for (id_list_ptr = list; id_list_ptr; id_list_ptr = id_list_ptr->next) {
pEp_identity* curr_identity = id_list_ptr->ident;
if (curr_identity) {
@ -492,11 +493,11 @@ static PEP_STATUS update_identity_recip_list(PEP_SESSION session,
char* name_bak = curr_identity->username;
curr_identity->username = NULL;
status = update_identity(session, curr_identity);
if (name_bak &&
if (name_bak &&
(EMPTYSTR(curr_identity->username) || strcmp(name_bak, curr_identity->username) != 0)) {
free(curr_identity->username);
curr_identity->username = name_bak;
}
}
}
else
status = _myself(session, curr_identity, false, false, true);
@ -504,8 +505,8 @@ static PEP_STATUS update_identity_recip_list(PEP_SESSION session,
return status;
}
}
return PEP_STATUS_OK;
return PEP_STATUS_OK;
}
PEP_STATUS MIME_decrypt_message(
@ -528,10 +529,10 @@ PEP_STATUS MIME_decrypt_message(
if (!(mimetext && mime_plaintext && keylist && rating && flags && modified_src))
return PEP_ILLEGAL_VALUE;
PEP_STATUS status = PEP_STATUS_OK;
PEP_STATUS decrypt_status = PEP_CANNOT_DECRYPT_UNKNOWN;
message* tmp_msg = NULL;
message* dec_msg = NULL;
*mime_plaintext = NULL;
@ -575,7 +576,7 @@ PEP_STATUS MIME_decrypt_message(
if (!dec_msg && (decrypt_status == PEP_UNENCRYPTED || decrypt_status == PEP_VERIFIED)) {
dec_msg = message_dup(tmp_msg);
}
if (decrypt_status > PEP_CANNOT_DECRYPT_UNKNOWN || !dec_msg)
{
status = decrypt_status;
@ -599,7 +600,7 @@ PEP_STATUS MIME_decrypt_message(
free(dec_msg);
return decrypt_status;
}