| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
Required to test how gjs handles this case.
|
|
|
|
|
|
| |
This allows to perform more introspection tests in gjs and other
implementations when it comes to set/get fields or "cast" an union
member to the main union type
|
|
|
|
|
|
|
| |
Such kind of arrays can be easily be allocated as we know the size of
each array element.
See: https://gitlab.gnome.org/GNOME/gjs/-/merge_requests/806
|
|
|
|
|
| |
We can use them in Gjs to verify whether a value is properly packed
and unpacked to GValue.
|
|
|
|
| |
It's the only basic type missing, better to have for consistency.
|
|
|
|
|
|
|
|
|
| |
The (out caller-allocates) and (out callee-allocates) annotations are
meant for structured or pointer types. Plain old data types are just
regular out parameters and don't need the annotation about who allocates
them.
See: https://gitlab.gnome.org/GNOME/glib/-/merge_requests/2005
|
|
|
|
|
|
|
|
| |
It is worth to test marshalling of signal arguments, add
a basic (and barebones) object to add signals and emission
methods to, so bindings can test the signal handlers.
Related: https://gitlab.gnome.org/GNOME/gjs/-/issues/377
|
|
|
|
|
|
|
|
| |
Bindings sometimes need to handle flags and enums separately, so
everything that is tested for enums should ideally be tested separately
for flags.
Signed-off-by: Simon McVittie <smcv@debian.org>
|
|
|
|
|
|
|
| |
We already had a test for enums, but flags are not precisely the same,
so testing both can give bindings better coverage.
Signed-off-by: Simon McVittie <smcv@debian.org>
|
|
|
|
|
|
|
|
|
| |
parameters
Virtual functions may use input/output parameters but this is not currently
well handled by gjs, so adding test cases to gobject-introspection to verify
that virtual functions correctly receive valid input values and can return
them.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
of structures
Prior to this, the only marshalling test cases available for GPtrArrays were
for GPtrArrays of strings.
This commit adds a marshalling test case for GPtrArrays of structures, with the
same objective than the gi_marshalling_tests_array_zero_terminated_return_struct() test case.
This also adds a similar marshalling test case for GArrays of structures, for
completeness.
This is a follow-up to https://gitlab.gnome.org/GNOME/gjs/issues/9 where a
regression has been detected with these types of GPtrArrays.
|
|
|
|
|
|
|
| |
These functions were removed a long time ago in commit af7be95a. Being
present in the header file means they are present in the generated GIR
file, but trying to resolve them with dlsym will fail and crash the
program.
|
|
|
|
|
|
| |
Note this is currently supported by neither [PyGObject][0] nor GJS.
[0] https://gitlab.gnome.org/GNOME/pygobject/issues/37
|
|
|
|
|
| |
Compiling these gives warnings about const or non-const expressions. Fix
it by using the correct const-ness of types.
|
|
|
|
|
|
| |
This is to test GJS's support of GValues boxed inside GValues.
https://bugzilla.gnome.org/show_bug.cgi?id=688128
|
|
|
|
|
|
|
| |
These will be used by pygobject in
https://bugzilla.gnome.org/show_bug.cgi?id=726484
https://bugzilla.gnome.org/show_bug.cgi?id=780652
|
|
|
|
|
|
|
| |
In order to test GJS's support for GHashTables with float, double,
gint64, and guint64 value types, here are some new GI marshalling tests.
https://bugzilla.gnome.org/show_bug.cgi?id=773763
|
|
|
|
|
|
|
| |
Since we return a static const array as the out value, the function must
have a const type for its out parameter.
https://bugzilla.gnome.org/show_bug.cgi?id=772790
|
|
|
|
|
|
|
|
| |
GJS has gained some support for marshalling arrays of previously
unsupported types. These are the marshalling tests that are needed to
test that new functionality.
https://bugzilla.gnome.org/show_bug.cgi?id=772790
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
What we already had:
- (array zero-terminated=1) > array which is NULL terminated
- (array zero-terminated=0) > array which is not NULL terminated
- (array) > array which is not NULL terminated
- (array zero-terminated=X) > array which is not NULL terminated
where X can be anything
What this patch adds:
- (array zero-terminated) > array which is NULL terminated
https://bugzilla.gnome.org/show_bug.cgi?id=657754
|
|
|
|
|
|
|
|
|
| |
This updates the test headers and sources to decorate the symbols with the
macro that can be used to export the symbols, and include config.h first in
the c-sources so that the macro can be defined with the compiler directive
to export the symbols.
https://bugzilla.gnome.org/show_bug.cgi?id=732669
|
|
|
|
|
|
| |
Make sure a constructor that sets a GError works correctly.
https://bugzilla.gnome.org/show_bug.cgi?id=727004
|
|
|
|
|
|
|
| |
The implementation as a method returning itself as its implemented
interface type.
https://bugzilla.gnome.org/show_bug.cgi?id=727824
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=722899
|
|
|
|
|
|
|
|
| |
Add test method with an allow-none in the middle of non allow-none
arguments. Add test method with an array and its length argument
interleaved with allow-none arguments.
https://bugzilla.gnome.org/show_bug.cgi?id=640812
|
|
|
|
|
|
|
|
| |
Add test function which accepts multiple allow-none utf8 arguments.
This can be used for testing a default of NULL for unsupplied
arguments annotated with allow-none.
https://bugzilla.gnome.org/show_bug.cgi?id=640812
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=701058
|
|
|
|
|
|
| |
It's breaking the gjs test suite
https://bugzilla.gnome.org/show_bug.cgi?id=698698
|
|
|
|
|
|
|
| |
Change mistaken return type of GIMarshallingTestsFlags to
GIMarshallingTestsEnum in vfunc_return_enum.
https://bugzilla.gnome.org/show_bug.cgi?id=637832
|
|
|
|
|
|
|
| |
Add vfuncs and methods for an object returning an enum or
using one as an output argument.
https://bugzilla.gnome.org/show_bug.cgi?id=637832
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add a number of vfuncs and methods which can be used for testing
marshaling of objects with different combinations of ownership
transference. An important part of these test vfuncs and methods is
they do not pass object returns and arguments through them. Instead
the methods return reference counts and floating attributes. This allows
isolation and ensures any problem with round trip object marshaling
does not obscure what should be tested from the perspective of C as the
caller of a vfunc. Tests and vfuncs can then be written in any language
with gi bindings.
https://bugzilla.gnome.org/show_bug.cgi?id=687522
|
|
|
|
|
| |
Fix (void) function declarations that occur with -Wstrict-prototypes, and the
g_param_spec_get_name() which drops the const from its argument.
|
|
|
|
|
|
|
| |
Add gi_marshalling_tests_param_spec_in_bool(), supplementing the already
existing tests for a GParamSpec out argument and return value.
https://bugzilla.gnome.org/show_bug.cgi?id=682355
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=684059
|
|
|
|
|
|
| |
Co-Authored-By: Martin Pitt <martinpitt@gnome.org>
https://bugzilla.gnome.org/show_bug.cgi?id=678401
|
|
|
|
|
|
| |
Add vfunc_array_out_param to GIMarshallingTestsObjectClass.
https://bugzilla.gnome.org/show_bug.cgi?id=690851
|
|
|
|
|
|
|
|
| |
We already have tests for "array of simple structs"
(gi_marshalling_tests_array_simple_struct_in) and "array of pointers to
boxed structs" (gi_marshalling_tests_array_struct_in), but were missing
"array of boxed structs", which reproduces
https://bugzilla.gnome.org/show_bug.cgi?id=656312
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=690041
|
|
|
|
| |
Will be used by gjs
|
|
|
|
|
|
|
| |
Add virtuals method which takes both an (in) and and (out) argument, and
variants with both caller and callee allocation.
This came up in https://bugzilla.gnome.org/show_bug.cgi?id=688783
|
| |
|
|
|
|
|
|
| |
gi_marshalling_tests_genum_returnv() should (and does) return a
GIMarshallingTestsGEnum, not a GIMarshallingTestsEnum. The latter is already
covered by gi_marshalling_tests_enum_returnv().
|
|
|
|
|
|
| |
Will be used by gjs for new byte array work.
https://bugzilla.gnome.org/show_bug.cgi?id=687696
|
|
|
|
|
|
|
|
| |
"int8" apparently blows up on AIX. It was kind of lame how we would
just ad-hoc append a _. Since we only have one value for a lot of
these, let's just go with the couldn't-be-any-simpler "v".
https://bugzilla.gnome.org/show_bug.cgi?id=664166
|
|
|
|
| |
Dear Python programmers, () doesn't mean what you think it means in C.
|
|
|
|
|
|
|
|
| |
Add in/out API for testing arrays containing uint64, as well as GList
containing uint32 (GList and GHash can't contain 64 bit values as they store
them in pointers).
https://bugzilla.gnome.org/show_bug.cgi?id=685860
|
|
|
|
| |
See https://bugzilla.gnome.org/show_bug.cgi?id=683596
|
|
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=681565
Co-Authored-By: Martin Pitt <martinpitt@gnome.org>
|
|
|
|
|
|
|
|
|
|
|
| |
Add a new interface GIMarshallingTestsInterface3 with a method that takes an
array of variants as argument. This can be used for testing the passing of
array of variants from C to introspection clients, which is not otherwise
covered in the tests for arrays of variants.
https://bugzilla.gnome.org/show_bug.cgi?id=667244
Signed-off-by: Martin Pitt <martinpitt@gnome.org>
|