File: test-activity.c

package info (click to toggle)
phosh 0.51.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 9,620 kB
  • sloc: ansic: 81,727; xml: 3,903; python: 502; sh: 456; makefile: 34; lisp: 22; javascript: 6
file content (29 lines) | stat: -rw-r--r-- 617 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
/*
 * Copyright (C) 2018 Purism SPC
 *
 * SPDX-License-Identifier: GPL-3.0-or-later
 *
 * Author: Guido Günther <agx@sigxcpu.org>
 */

#include "activity.h"

static void
test_phosh_activity_new(void)
{
  PhoshActivity *activity = PHOSH_ACTIVITY (phosh_activity_new ("com.example.foo"));
  g_assert (activity);
  g_assert_cmpstr (phosh_activity_get_app_id (activity), ==, "com.example.foo");
  gtk_widget_destroy (GTK_WIDGET (activity));
}


int
main (int   argc,
      char *argv[])
{
  gtk_test_init (&argc, &argv, NULL);

  g_test_add_func("/phosh/activity/new", test_phosh_activity_new);
  return g_test_run();
}