1
0
mirror of https://github.com/moparisthebest/pacman synced 2024-08-13 17:03:46 -04:00
Commit Graph

158 Commits

Author SHA1 Message Date
Chantry Xavier
ac0605b9c2 new upgade042 pactest + bugfix in chk_filedifference.
This adds a pactest for the relocation of a config file between two packages
(case of etc/profile moving from bash to filesystem).
While running this pactest, I found out that chk_filedifference didn't work
correctly with an empty list as second argument. So that's fixed now.

Ref: http://www.archlinux.org/pipermail/pacman-dev/2007-December/010610.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2008-01-01 20:03:18 -06:00
Dan McGee
fbd88a8212 Remove .FILELIST generation from makepkg (and elsewhere)
This is something pacman can do on its own straight from the archive, and we
will reduce the chance of problems occurring becuase of inproper FILELIST
generation as we have had in the past with special characters in filenames.

Once we remove it from makepkg. we can remove any usage of it from all of
our other tools, including pacman, pactest, and contrib/ utilities.

Note that removing it from pacman uncovered a few other bugs anyway, so this
was probably a good move.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-29 11:58:23 -06:00
Chantry Xavier
01930400a5 add a new upgrade026 pactest for backup handling.
This is the bash case when the /etc/profile file was removed by error from
the package, but stayed in the backup array.

Ref:
http://www.archlinux.org/pipermail/arch-dev-public/2007-December/003556.html

Also fixed a little typo in add.c, but it's disabled code.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-12-29 11:17:20 -06:00
Chantry Xavier
73aa6b610e fix two broken pactests because of date localization.
query002 and sync1100 had PACMAN_OUTPUT rules that looked at the
build/install date (localized).
Instead of looking at the month name, it will now check the year, which
should be safer.
I also had to add another pactest (query005) for keeping the same coverage.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-12-28 19:56:29 -06:00
Nagy Gabor
13dd2864ca PM_DEP_MOD_LT and PM_DEP_MOD_GT depmods added
You can use foo<2.0 and foo>2.0 as depend
add046.py and add047.py pactests were added to check this

Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-19 14:48:05 -06:00
Aaron Griffin
f5478d68a6 Add real scriptlet checking for pactest
Due to commit da1222de2e30aabcae9d17bbfa10bbf0672338af, we can now use
fakechroot to completely run scriptlet pactests

Use "which" functionality so as not to REQUIRE it for all users

Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-10 23:06:48 -06:00
Aaron Griffin
685a659656 Add "which" path searching functionality to pactest
Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
2007-12-10 23:06:03 -06:00
Aaron Griffin
f8b113ed97 Fail sanely on OUTPUT rules when --nolog is passed
Check for existence of the logfile first, and output an error if not found

Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-10 23:02:20 -06:00
Dan McGee
9781d0d637 Update GNU GPL boilerplate and copyright dates
Update the GPL boilerplate to direct people to the GNU website for a copy of
the license, as well as bump all of Judd's copyrights to 2007.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-10 22:55:39 -06:00
Dan McGee
572bdb5c99 pactest: if we are root, don't use fakeroot
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-10 21:17:39 -06:00
Dan McGee
94aa8b1f16 Add a lot more tests (and some pactest fixes) to -Si and -Qi tests
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-02 18:11:23 -06:00
Dan McGee
e8eff3ef97 Add more pactests to increase code coverage
These new tests test the following ops at least once:
-Ss, -Si, -Sl, -Sp, -Qs, -Qi, -T

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-02 17:56:48 -06:00
Dan McGee
7341d09541 Add 4 new pactests to get better code coverage by pactest
I started playing around with gcov today and it showed a few places in the
code that we don't test at all. This is the start of ensuring that we
execute most of the code in our codebase.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-02 17:24:22 -06:00
Nagy Gabor
f19820cba8 New sync1005 and sync1006 pactests
This pactest checks what happens if a package exists in two sync repos.

Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu>
[Dan: added sync1006, same test with different versions]
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-12-01 11:29:41 -06:00
Nagy Gabor
7d37d9278d Fix for sync1003 and sync1004 pactests
checkdeps and resolvedeps now take both a remove list and an install list as
arguments, allowing dependencies to be calculated correctly.

This broke the sync990 pactest, but this pactest used dependencies and
provides in an unusual way, so it has been changed.

Dan: the sync990 pactest was just plain wrong. It didn't satisfy the
dependencies correctly, so should never have succeeded.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
[Dan: some variable renaming, clarification in commit message]
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-25 15:29:37 -06:00
Dan McGee
f5d2150e9d Remove -F/--freshen operation
This operation made sense in the days before sync DBs existed, but it no
longer has the same usefulness it once did.

Signed-off-by: Dan McGee <dan@archlinux.org>
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu>
Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
2007-11-21 11:51:17 -06:00
Nagy Gabor
84ebf82319 Versioned provisions.
This patch introduces versioned provisions in "provision 1.0-1" format.
_alpm_db_whatprovides was modified accordingly (added sync500.py),
alpm_depcmp was modified accordingly (add043.py passes now; added add044.py
and add045.py).

Notes:
alpm_db_search now uses the whole versioned %PROVIDES% string in its search.
debug logging was simplified in alpm_depcmp.

Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu>
[Xavier: fixed a few typos, duplicate const strings with strdup before
modifying them, put some debugging back in alpm_depcmp, minor code cleanups
(var/function renaming), added a note in PKGBUILD man page.]
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
[Dan: made strcmp checks clearer, added a comment]
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-18 20:05:51 -06:00
Dan McGee
ceb870655e Remove REQUIREDBY checks from pactest
Remove any checks dealing with requiredby from pactest (but not actually
from the pactests themselves). Of course, we should probably find a new way
to check requiredby values of packages since there is no guarantee our code
is working perfectly.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-14 18:49:50 -06:00
Nagy Gabor
f5fcaf0b3c new trans001.py pactest
The pactest demonstrates what happens if fileconflict was found after the
removal part of a sync transaction.

Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-14 18:49:02 -06:00
Nagy Gabor
1d57a3e801 new add043.py pactest
Currently alpm_depcmp uses pkg->version as a version number for provisions,
which is odd.  The failure of the pactest demonstrates this.

Signed-off-by: Nagy Gabor <ngaba@bibl.u-szeged.hu>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-14 18:49:02 -06:00
Nathan Jones
ca262623fc Add pactest for IgnoreGroup.
Also tell pactest to reset IgnoreGroup like it does for IgnorePkg.

Signed-off-by: Nathan Jones <nathanj@insightbb.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-13 00:13:04 -06:00
Chantry Xavier
96f8faa666 Add two requiredby pactests
One currently should succeed (006), and 005 fails.

requiredby005.py is originally from Nagy Gabor <ngaba@petra.hos.u-szeged.hu>.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-11 10:52:51 -06:00
Dan McGee
a55a07f5dd Add a symlink-based pactest
This passes with both the upcoming 3.1 devel tree and the 3.0.6 pacman code.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-11 09:51:09 -06:00
Jeff Mickey
bcb5465b21 Added optdepends support to pactest
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-11-04 09:48:24 -06:00
Chantry Xavier
014306eb99 simple pactest renaming : split conflict* into depconflict* and fileconflict*.
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-10-29 07:15:41 -05:00
Dan McGee
671224b64c pactest: generate the filelist the correct way
Actually use python commands to generate the filelist instead of os.system
calls that don't necessarily work everywhere. Noticed when running "make
check" on FreeBSD where the tar program is actually bsdtar.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-10-28 22:24:11 -05:00
Chantry Xavier
0dc34f496d extend type001 pactest with a symlink.
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-10-28 21:18:55 -05:00
Dan McGee
128b288ca7 Fix scriptlet pactest cases so they 'succeed' again
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-10-14 18:52:17 -05:00
Nagy Gabor
3c4e98f7b5 Add two new pactests to check symlink behavior
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-10-09 13:27:08 -05:00
Nagy Gabor
3d8408759d Add new (failing) sync pactest
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-10-08 20:46:55 -05:00
Dan McGee
843d368ef6 libalpm/add.c: fix backup array issue
As seen with the recent upgrade of pacman and the removal of the
pacman.d/current mirrorlist, files that were formerly in the backup array
get deleted upon their removal, which could be dangerous. Instead, we should
use the combined backup array of the old and new package. This fix should
address this issue in a relatively straightforward way.

In addition, old files should be moved to pacsave locations as expected.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-09-23 20:48:04 -05:00
Chantry Xavier
105fd40a4a Add sync044 pactest : A dependency induces a replacement.
That is the problem mentioned by Nagy there (with suggestions for fixing it) :
http://www.archlinux.org/pipermail/pacman-dev/2007-August/009082.html

If a dependency conflicts with a local package and has to replace it,
the PM_SYNC_TYPE_DEPEND information is lost, and the resulting install
reason is wrong (the package is marked as explictly installed).

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-09-23 19:50:11 -05:00
Chantry Xavier
6898bb0f97 Add two pactests with broken requiredby, and two about pacsave handling.
remove048 is the case mentioned there (fails in 3.0 but works in 3.1) :
http://www.archlinux.org/pipermail/pacman-dev/2007-September/009294.html
It's the same as remove046 with -R instead of -Rc.

sync060 is a case reported this morning on IRC :
a pacman -Su wanted to replace gensplashutils by gensplash,
but pacman said gensplashutils was required by initscripts-gensplash,
while initscripts-gensplash was not even installed.
This is also fixed in the current 3.1 code though.

upgrade02{4,5} are the backup handling problem I described there :
http://www.archlinux.org/pipermail/pacman-dev/2007-September/009376.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-09-23 19:50:03 -05:00
Dan McGee
b2501950c7 Fix sync db location in pactest so new location is acceptable
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-09-06 19:52:55 -05:00
Chantry Xavier
53fc745aed Add a few pactests collected over time.
remove047 : Remove a package required by other packages

conflict004 : a package conflicts with itself
  http://www.archlinux.org/pipermail/pacman-dev/2007-August/009077.html

sync400 : Install package with dep that conflicts with older version of package
sync401 : Ensure we choose provider already in target list
  http://www.archlinux.org/pipermail/pacman-dev/2007-July/009041.html

sync402/sync403 (failing) : Choice between two providers
  http://www.archlinux.org/pipermail/pacman-dev/2007-July/008787.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-09-06 19:30:18 -05:00
Nagy Gabor
13525255dc Add sync1003 pactest.
The sync package pkg3 depends on the sync package pkg2, but pkg1 replaces pkg2.
So pkg2 is added to the remove list.

When checkdeps checks if pkg2 can be removed, it looks at the packages that require pkg2
(with the RequiredBy field of pkg2), but this doesn't contain pkg3 at this point.
RequiredBy fields are only updated after the packages are installed.

Proposed solution : checkdeps should know both the remove and upgrade list to decide properly.

Reference:
http://www.archlinux.org/pipermail/pacman-dev/2007-July/008972.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-08-20 15:24:28 -04:00
Nagy Gabor
b1808930ce libalpm/add.c,trans.c : cleanup of requiredby handling.
This patch cleans up and fix the _alpm_trans_update_depends function
and ensure that all requiredby fields are filled in case of multiple satisfiers
(previously, the handling of mutliple satisfiers in that function was inconsistent).

This makes a special case handling of requiredby in commit_single_pkg() obsolete,
and so allows cleaning that code as well.

Also fixed upgrade056 pactest because :
1) the requiredby fields were wrong, and this wouldn't happen with the fixed _alpm_trans_update_depends().
2) this is a very unusual case anyway (and handling all corner cases combined to a broken database
  seems nearly impossible to achieve).

References :
http://www.archlinux.org/pipermail/pacman-dev/2007-July/008919.html
http://www.archlinux.org/pipermail/pacman-dev/2007-July/008920.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-08-20 15:23:53 -04:00
Nagy Gabor
b96922679e Add two pactest for versioned conflicts.
A side effect of the previous commit ( ea9a756eea )
is that it's now possible to use versioned conflicts.
Add two new conflict pactests for showing it.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-08-12 21:14:05 -04:00
Nagy Gabor
72c15482dc add conflict001 pactest.
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-20 10:42:01 -04:00
Nagy Gabor
5991e85abb Add sync1002 pactest.
Reference:
http://www.archlinux.org/pipermail/pacman-dev/2007-July/008971.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-20 10:33:42 -04:00
Dan McGee
466d289e6a Remove unnecessary entries from .gitignore files
.gitignore works recursively, so we don't need Makefile and Makefile.in
in all of the subdirectory .gitignore files.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-07-16 16:49:28 -04:00
Chantry Xavier
ab2354e762 Add remove046 pactest for FS#7622.
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-16 09:20:17 -04:00
Chantry Xavier
aaf291c11c Add new sync012 pactest.
This test installs three packages with a circular dependency,
to check everything still goes fine in that case.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-15 19:46:18 -04:00
Dan McGee
a1e57cbec8 Add --asdeps option to pacman
This replaces the former -D operation that was undocumented and rather
hacky. It can be used with add, upgrade, or sync transactions and will affect
all packages installed. Should close FS #7193.

Also tell makepkg to use this new flag.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-07-15 12:46:02 -04:00
Nagy Gabor
c2920033d0 libalpm/deps.c : cleanup + little fix for resolvedeps.
The resolvedeps function was a bit negligent, as showed by the sync011 pactest.
Reference :
http://www.archlinux.org/pipermail/pacman-dev/2007-July/008782.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-15 10:37:38 -04:00
Chantry Xavier
5ed501565e remove sync022 and sync023 pactest.
Currently the replaces flag is only used for forcing the replacement
of package (eg because of a renaming) on sysupgrade operation.

If the replaces flag should also be used for resolving conflicts,
then it should be discussed and specified correctly first.

References:
http://bugs.archlinux.org/task/7415#comment17207
http://www.archlinux.org/pipermail/pacman-dev/2007-June/008553.html
commit which introduced the replace flag : 4fcec8f03f

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-13 10:11:54 -04:00
Dan McGee
37736a56f9 Add new pactest that is backwards of sync022
sync022 was added here:
39b6549655

This pactest reverses the installed package to see if it is correctly
picked, in order to test some further changes to this depcheck code that
currently makes sync022 fail.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-07-11 00:45:15 -04:00
Chantry Xavier
862ea62761 add remove045 pactest.
Another test a bit more complicated for -Rs,
to prevent regression if removedeps is changed.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-10 11:10:54 -04:00
Nagy Gabor
c4e712c0ef add remove044 pactest.
This indicates a problem in the current removedeps function
(no version checking) for which Nagy proposed a fix here :
http://www.archlinux.org/pipermail/pacman-dev/2007-June/008539.html

But as he mentioned there, a better fix might be to use the checkdeps
function in the removedeps one.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-07-10 11:10:54 -04:00
Dan McGee
6b7b974318 Fix up pactest TODO
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-07-06 00:33:26 -04:00
Dan McGee
59d9ccf48d Reduce delay in pactest when running MODIFIED tests
pactest was sleeping for 3 seconds, which is unnecessary. Reduce it to 1.5
seconds and clean up the code a bit anyway.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-07-02 10:06:03 -04:00
Dan McGee
19f66083f0 Add mode and type checking to pactest for files
Add the ability to check the permissions and type of a file within the
framework of pactest. Two new rules can be used:

self.addrule("FILE_TYPE=bin/foo|file")
self.addrule("FILE_MODE=bin/bar|644")

TODO: add the ability to add different types of files (eg links) via the test
package building framework, and add the ability to change the modes on files.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-07-01 20:03:15 -04:00
Dan McGee
7daa6708d2 Remove lockfile configuration from frontend, make it job of libalpm
I previously introduced some patches to make just about every path in
pacman/libalpm configurable; doing this with the lockfile seemed a bit too
far and we really should just place the lockfile where it belongs- with the
DB that needs locking.

More details in this thread:
http://archlinux.org/pipermail/pacman-dev/2007-June/008499.html

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-27 23:34:38 -04:00
Chantry Xavier
31cbbbf953 Add pactest to help debug FS #7415
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-26 15:27:56 -04:00
Chantry Xavier
0e4c1e86ed Add sync301 pactest- pacman gains new deps and should be pulled in
Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-26 12:00:22 -04:00
Nagy Gabor
e2a75a8257 Add pactest requiredby004.
Upgrade a package that no longer needs a depend.
Reference:
http://www.archlinux.org/pipermail/pacman-dev/2007-June/008503.html

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-12 16:19:50 -04:00
Nagy Gabor
2746a6319a Add new pactest remove043.
Remove a package required by another package.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
2007-06-11 11:21:19 +02:00
Dan McGee
07069cd502 pactest: fix description of remove040
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-10 21:33:24 -04:00
Chantry Xavier
1da78a7d25 Add two new pactests for FS #6057
As described in the bug report, installing taglib-rcc (sync900 pactest)
works fine. But installing taglib back (sync901 pactest) doesn't.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-10 20:14:20 -04:00
Chantry Xavier
ece1ee7ef2 Add new pactest remove042
Same as remove040, with cascaded remove instead of simple remove.

Signed-off-by: Chantry Xavier <shiningxc@gmail.com>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-10 17:41:35 -04:00
Andrew Fyfe
e0afe6e94a Autotool clean up.
* Add vim modeline to Makefile.am and configure.ac
	* Fix white space in Makefile.am and configure.ac
	* Add contrib/wget-xdelta.sh to EXTRA_DIST in Makefile.am

Signed-off-by: Andrew Fyfe <andrew@neptune-one.net>
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-04 22:24:29 -04:00
Nagy Gabor
029a8a9d44 Add five new pactest tests where pacman currently fails
Most of these new tests deal with provisions upon sync or upgrade being
changed by packages, and pacman not being smart enough to deal with
it yet.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-06-04 17:00:30 -04:00
Dan McGee
7bd2ff6851 Move DB and cache dirs away from there dependence on ROOTDIR
This change allows us to use all autoconf specified paths, most notably
$(localstatedir). It is quite a change and touches a lot of files, as
all references to the DB and cache were done with the ROOTDIR as a prefix.

* add --lock command-line option to pacman to specify the location of the
  lockfile (this can now be specified at configure time by setting the
  $localstatedir path).
* Rip quite a few settings out of configure.ac as they are now picked by
  setting the paths during configure or make.
* Fix bug with /tmp fallback for sync downloads not working correctly
  (related to root location, now the system tmp dir is used).
* Simplified the parameters to some libalpm functions, and added get/set
  for the new lockfile option.
* Renamed several of the DEFS to names without the PM_ prefix.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-05-31 02:51:28 -04:00
Dan McGee
a1adddddfe Add three new 'requiredby' pactests
These should test various aspects of the DB when dealing with requiredby
entries. At least one fails without Nagy's alpm_depcmp patch.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-05-14 10:56:52 -04:00
Dan McGee
fa542515e6 Add a pactest for IgnorePkg and force on same package
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-04-23 02:44:24 -04:00
Aaron Griffin
3929bbfb7b ldconfig changes from CVS
forward-porting some 3.0.2 changes
* Nagy's ldconfig fix
* 3 new pactests to check if ldconfig runs
Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
2007-04-16 20:34:57 -05:00
Dan McGee
1c2358532f Add pactest for pre_ and post_remove scriptlet events firing
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-04-07 16:27:32 -04:00
Aaron Griffin
15a1b06d36 pactest: remove001.py
* Test for duplicate remove targets (should succeed)

Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
2007-04-04 19:24:02 -05:00
VMiklos
ea3a182dbf New pactest: Sysupgrade with a sync package forcing a downgrade
Signed-off-by: Dan McGee <dan@archlinux.org>
2007-04-01 21:52:28 -04:00
Dan McGee
8cacc46f8b Move .cvsignore -> .gitignore
* Move all .cvsignore files to .gitignore for switch in VCS. In addition,
  delete ones that were unnecessary because they only contained Makefile
  and Makefile.am.

Signed-off-by: Dan McGee <dan@archlinux.org>
2007-03-27 21:06:31 -04:00
Dan McGee
58fe79eef6 * Fix bug where 'makepkg -L' doesn't stop on build failure.
Andrew Fyfe <andrew@neptune-one.net>
* Add testing to etc/pacman.d/.cvsignore
* Fix scriptlet001.py test to work during 'make check'.
2007-03-25 17:37:42 +00:00
Aaron Griffin
bdfe232b8a Quick pactest changes:
* Minor change to utils.py(grep) to make it cleaner
* Added scriptlet check to verify scriptlet events happen
2007-03-22 08:30:18 +00:00
Dan McGee
3a4030837e * Updated Italian translation
Giovanni Scafora <linuxmania@gmail.com>
* Added pactest test for -Se operation
  James Rosten <seinfeld90@gmail.com>
2007-03-21 22:15:50 +00:00
Aaron Griffin
bd55cf548c James Rosten <seinfeld90@gmail.com>
* Two new pactest test cases
* Fix some "required by" / "requires" output by unifying all "dependency types"
  to a single value (PM_DEP_TYPE_DEPEND)
2007-03-19 04:23:45 +00:00
Dan McGee
869e81e1cf This commit looks much more monumental than it is. Almost all just #include
reordering and adding ones that were forgotten (noticed when trying to
compile after reordering).

* Updated the HACKING file to include information on #include usage.
* print -> vprint in "making dir" function in pactest.
2007-03-05 22:13:33 +00:00
Aaron Griffin
94b5e39407 Added this test to check the XferCommand functionality 2007-03-05 18:06:45 +00:00
Aaron Griffin
2caadb33bf * Fixed an issue with globbing the --test argument
* Added a custom 'mkdir' function which makes parents and doesn't fail on
  existence
* Added output for 'SKIP' messages (it did not indicate WHY it was skipped)
* Added the ability to generate DB packages in the sync dir (not the cache dir)
  for testing downloading.  (self.cachepkgs = False)
* Added pmtest.path for the full path to the package file
2007-03-05 18:06:12 +00:00
Aaron Griffin
2ff33d8316 * By Roman's request - proactive backup=() entry test case 2007-03-04 10:27:49 +00:00
Aaron Griffin
eb8ae6cdc8 Added a test for checking 'requiredby' removal 2007-03-04 00:14:26 +00:00
Dan McGee
efca1cc010 * Modified values of INFRQ_* options so we start at 0x01 and not 0x00. This
allows for the same bit operators to be used across the board on pkg_get
  operations.
* Changed name of INFRQ_NONE -> INFRQ_BASE to more clearly reflect what it
  does (loads pkg name and version).
* Added a few missing things on package functions, such as SYMEXPORT and
  ALPM_LOG_FUNC.
* Slight updates to pmenv to print 'pass' and 'fail' instead of 'passed' and
  'failed'. Keeps output a bit more concise.
* Fixed a doxygen comment spelling error. :P
2007-03-01 19:07:38 +00:00
Aaron Griffin
6075b677fc * REQUIREDBY test was reversed (pkg3 requiredby pkg1, not pkg1 requiredby pkg3) 2007-03-01 06:54:05 +00:00
Dan McGee
77a9533b64 * Silly mistake on making sync895 and sync896- I didn't create the field
requiredby for 'already installed' packages, so the test didn't work
  properly. Once these errors were fixed, both tests pass fine.
2007-03-01 03:27:53 +00:00
Dan McGee
13e2111045 * Unifying placement of REPLACES in desc file, as pacman2 does. We'll worry
about bigger DB changes later, but lets not screw anything up for release.
* Removed some weird uses of "not ... ==" usage in pactest- correct me if I'm
  wrong, but isn't "!=" a lot more clean and concise?
* Print description of failed tests in the pactest summary. This could get
  dirty with a lot of failed tests though, so watch out.
2007-02-28 16:37:24 +00:00
Dan McGee
bd7eb9475c * Added another test as suggested by Nagy on the ML- a package both provides
for and is a dependency of another package. (upgrade057)
* Removed man2html stuff from doc/Makefile.am.
* Patch: improved depends checking in _alpm_checkdeps
  Nagy Gabor <ngaba@petra.hos.u-szeged.hu>
* Slight revisions to pmrule.py to allow for a PKG_PROVIDES test.
* Very quick updates to the pactest README.
* Added rules to some of the newer upgrade tests. Note: upgrade055 now fails
  due to requiredby entries not being written packages that are dependencies
  in a provides role.
2007-02-28 04:00:21 +00:00
Dan McGee
820fae9d75 * Some new tests. That bring new failures. :) 2007-02-27 20:49:23 +00:00
Dan McGee
7ee5a4e70f * Added another test- I believe it is a possible situation and one we need to
deal with. Currently, libalpm with AND without Nagy's patch fails it.
* Slight spacing update to pmenv.py.
2007-02-27 19:44:45 +00:00
Dan McGee
7f086a4c5c * Prevent this error when creating empty packages.
tar: *: Cannot stat: No such file or directory
  tar: Error exit delayed from previous errors
2007-02-27 16:25:01 +00:00
Dan McGee
6673d188b9 * Updated description of test upgrade052.
* Added the actual "Nagy's bug" as upgrade055.py.
* Updated the Makefile to distribute the pactest readme.
* Removed COPYING from the pactest directory- see COPYING at the root for the
  same license.
2007-02-27 16:15:47 +00:00
Aaron Griffin
512ccbd042 * Fixed a pacman warning when these fake packages didn't create an (empty)
.FILELIST
2007-02-27 08:32:52 +00:00
Aaron Griffin
67ff30b869 * This test was off. pactest doesn't do all the DB work, so we need to manually
add the "requiredby" information that libalpm would have written.
  Now it succeeds.
2007-02-27 08:29:02 +00:00
Dan McGee
f2ade9ab0d * Added 5 new upgrade tests, which check various things with depends,
provides, and conflicts.
  - upgrade051 is known to fail- but we want to eventually make it work.
  - upgrade052 is Nagy's bug as reported on the ML- I think. If it isn't,
    let me know.
2007-02-27 01:34:07 +00:00
Aaron Griffin
52376150fa * Writing 'replaces' info to both /desc and /depends files for testing - see the
"replaces confusion" thread on pacman-dev for more information
* Cleaned up some 2 item loops in the sync131 test
2007-02-26 08:33:48 +00:00
Aaron Griffin
25223d6790 * corrected (IMO) --debug usage with pactest. --debug is now passed straight
through to pacman, whereas --verbose affects the pactest output - this cleans
  up the standard test output significantly
* sorted tests a bit better, sectioning off failed tests AFTER successful tests,
  to make it easier to see what failed at a glance
* added a 'testname' member to pmtest, which strips path info (cleaner output)
2007-02-26 08:19:02 +00:00
Dan McGee
352913b994 * Oops. Messed a few things up, fixing them now. 2007-02-23 07:04:12 +00:00
Dan McGee
d9bd24c968 * Changes to quite a few of the tests, mostly minimal changes (better
descriptions, additional rules, etc)
* One new pactest test regarding file migration between packages.
* Fix of a little output bug in pmenv.py
2007-02-23 06:50:42 +00:00
Aaron Griffin
2f32a02f9d Ignore that... wasn't supposed to happen 2007-02-23 05:12:58 +00:00
Aaron Griffin
bfbba7628d *** empty log message *** 2007-02-23 05:11:43 +00:00
Aaron Griffin
94874d90e2 * Fixed globbing for pactest --test argument
* --manual-confirm was handled in the wrong order
2007-02-23 04:54:49 +00:00
Aaron Griffin
6cd69fa9ff * Removed a stray print statement left in there
* Fail when no tests defined
* Added --manual-confirm to help with hand testing
2007-02-23 04:22:21 +00:00
Aaron Griffin
d584d8c068 * Modified the handling and output w.r.t. IgnorePkg entries. -Sy always ignores
these packages, but -S explicitly asks for confirmation.
2007-02-23 02:10:56 +00:00