Commit Graph

66 Commits

Author SHA1 Message Date
Jonathan Lebon
1c81b7f56e test-ucontainer.sh: use test-repo in srcdir
Running `make check` would fail because test-ucontainer.sh uses
test-repo, which points directly to the installed_testdir, where it is
not installed yet.

We make another processed version of test-repo.repo.in which instead
points to the repo in the srcdir and make use of that in
test-ucontainer.sh.

There are probably other ways of solving this, but this is the one that
jumped out at me.
2016-02-23 17:53:46 -05:00
Colin Walters
58cf2c9403 tests: Add test coverage for rpm-ostree container 2016-02-22 14:27:46 -05:00
Colin Walters
06f5577770 tests: Use createrepo_c
It's what more components are standardizing on.
2016-02-22 14:27:46 -05:00
Jonathan Lebon
87423f5707 Makefile-tests.am: fix program typo in note
The note mentions ostree instead of rpm-ostree. Also reword double usage
of "use".
2015-09-11 10:25:38 -04:00
Colin Walters
7267c1ec05 tests: Import dbus-run-session
Unfortunately RHEL 7 has an older version of dbus, and I use it as a
workstation.  It's not a lot of code and only used for tests.  We can
make it build time conditional down the line or something.
2015-09-09 22:00:05 -04:00
Matthew Barnes
0326568a4a tests: Adapt to rpm-ostree daemon
No doubt better ways are possible but this is the least messy thing
I could come up on a deadline.
2015-09-09 22:00:05 -04:00
Colin Walters
7b45f13a62 Link lib/ against libpriv/, use it to share sack loading function
On the plus side, we share some code between the library and the
binary now.  On the downside, because `librpmostreepriv.la` is a
noinst library, its code text is duplicated between the shared library
and binary, at least until we either:

 - Have the binary solely use the public shared library (like ostree does)
 - Install `librpmostreepriv.so` to e.g. `/usr/lib64/rpm-ostree/librpmostreepriv.so`
   without the headers being public
2015-04-23 16:30:17 -04:00
Giuseppe Scrivano
ad30a790de Makefile-tests.am: clean generated files
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2015-04-22 11:41:03 +02:00
Giuseppe Scrivano
7d86f72c79 do not crash when no selinux tag is present
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2015-04-13 10:43:24 +02:00
Giuseppe Scrivano
27008e402a tests: Add test for compose
A local yum repository, which contains a dummy .rpm package adding
support for programs needed by the post-process phase, is created as
part of the test.

Since no libc is present, the empty.c program (which is a no-op)
directly invokes the interrupt 0x80 to exit.

The test works only on x86_64, it is skipped on other architectures.

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2015-04-13 10:43:24 +02:00
Giuseppe Scrivano
b2c3e8a264 make check: add note to run installed tests
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2015-04-13 10:43:24 +02:00
Giuseppe Scrivano
3360b2a404 tests/test-basic.sh: run only as part of installed tests
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
2015-04-13 09:59:32 +02:00
Colin Walters
a8a2049443 build: Split up src into app/ and libpriv/
We currently have an internal-only library, but the sources for it are
in the same dir as the app.  For future work on a public shared
library, we'll need a clearer source structure.

Start by just renaming the app files into `src/app/`, and the internal
private library into `src/libpriv/`, with the appropriate
`Makefile.am` changes.

Closes: https://github.com/projectatomic/rpm-ostree/pull/123
2015-04-08 16:17:06 -04:00
Colin Walters
fc1a4b05fa tests/jsonutil: New test
Adding some basic coverage of the json parsing.
2014-12-19 10:47:55 -05:00
Colin Walters
fee9f48409 tests: Enable glib-tap.mk
These files were taken from json-glib, around the era of this commit:

https://git.gnome.org/browse/json-glib/tree/build/autotools?id=2779d537492f1902d71cf648631238110b62b311

Unfortunately, this involved hacking it up a bit:
 - I couldn't easily use `nobase` for the data, so I deleted that.
   Test data goes in the installed-tests dir.
 - Delete duplicated predeclared variables; we're using nonrecursive
   make.
 - Ensure we run each test in its own tmpdir
2014-12-19 10:47:55 -05:00
Colin Walters
a32ac06ce9 Import some basic testing infrastructure from OSTree
This is using the
https://wiki.gnome.org/Initiatives/GnomeGoals/InstalledTests model.

In order to run the tests, you will need to:
./configure --enable-installed-tests

Then:
gnome-desktop-testing-runner -p 0 rpm-ostree/
2014-09-29 16:25:36 -04:00