File: test.in

package info (click to toggle)
gnome-maps 49.3-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 12,528 kB
  • sloc: javascript: 24,148; ansic: 3,301; xml: 299; makefile: 10; sh: 4
file content (21 lines) | stat: -rw-r--r-- 657 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
#!@GJS@
const Gio = imports.gi.Gio;

imports.package.init({ name: "@name@",
                       version: "@PACKAGE_VERSION@",
                       prefix: "@prefix@",
                       libdir: "@libdir@" });

log('program name: ' + imports.system.programInvocationName);
log('ARG: ' + imports.system.programArgs);

// manually load GResource from build tree for the generated test scripts
for (const arg of imports.system.programArgs) {
    const resource = Gio.Resource.load(arg);
    resource._register();
}

import(`resource:///org/gnome/Maps@suffix@/tests/@name@.js`).catch(error => {
    console.error(error);
    imports.system.exit(1);
});