~dobey/ubuntu-app-launch/ship-app-mock

« back to all changes in this revision

Viewing changes to tests/libual-cpp-test.cc

  • Committer: Bileto Bot
  • Author(s): Ted Gould
  • Date: 2017-02-15 15:09:22 UTC
  • mfrom: (287.2.2 remove-log-function)
  • Revision ID: ci-train-bot@canonical.com-20170215150922-y1hcfeghb6lwgt9b
Remove unused log functions

Approved by: Charles Kerr

Show diffs side-by-side

added added

removed removed

Lines of Context:
694
694
}
695
695
#endif
696
696
 
697
 
/* NOTE: The fact that there is 'libertine-data' in these strings is because
698
 
   we're using one CACHE_HOME for this test suite and the libertine functions
699
 
   need to pull things from there, where these are only comparisons. It's just
700
 
   what value is in the environment variable */
701
 
TEST_F(LibUAL, ApplicationLog)
702
 
{
703
 
    auto appid = ubuntu::app_launch::AppID::parse("com.test.good_application_1.2.3");
704
 
    auto app = ubuntu::app_launch::Application::create(appid, registry);
705
 
 
706
 
    EXPECT_EQ(
707
 
        std::string(CMAKE_SOURCE_DIR "/libertine-data/upstart/application-click-com.test.good_application_1.2.3.log"),
708
 
        app->instances()[0]->logPath());
709
 
 
710
 
    appid = ubuntu::app_launch::AppID::find(registry, "single");
711
 
    app = ubuntu::app_launch::Application::create(appid, registry);
712
 
 
713
 
    ASSERT_LT(0, int(app->instances().size()));
714
 
 
715
 
    EXPECT_EQ(std::string(CMAKE_SOURCE_DIR "/libertine-data/upstart/application-legacy-single-.log"),
716
 
              app->instances()[0]->logPath());
717
 
 
718
 
    appid = ubuntu::app_launch::AppID::find(registry, "multiple");
719
 
    app = ubuntu::app_launch::Application::create(appid, registry);
720
 
 
721
 
    EXPECT_EQ(std::string(CMAKE_SOURCE_DIR "/libertine-data/upstart/application-legacy-multiple-2342345.log"),
722
 
              app->instances()[0]->logPath());
723
 
}
724
 
 
725
697
TEST_F(LibUAL, ApplicationPid)
726
698
{
727
699
    /* Check bad params */