andy128k / cl-gobject-introspection

BSD 2-Clause "Simplified" License
49 stars 15 forks source link

Add regression test suite with fiveam #9

Closed hying-caritas closed 10 years ago

hying-caritas commented 10 years ago

We can add more test cases in the future.

Known issues: cannot run multiple times in slime. Because gtk-init-check is used in test suite. But I can not found another worked function with in-out parameters.

Kalimehtar commented 10 years ago

You may use gtk_widget_destroyed

Would you be so kind, to create cl-gobject-introspection-test.asd with test package and its dependencies, to avoid fiveam dep in main ASD.

hying-caritas commented 10 years ago

Sorry, just found your comments. Will create cl-gobject-introspection-test.asd.

hying-caritas commented 10 years ago

For gtk_widget_destroyed, I still want to keep test suite usable under non-X11 environment. Do you think this is a valid target? And I still want to have a pure function test case for in-out argument. To run test suite I use the following command line:

$ sbcl --noinform --no-userinit --eval "(require \"asdf\")" --eval "(require \"cl-gobject-introspection\")" --eval "(require \"cl-gobject-introspection-test\")" --eval "(gir-test:main)" --quit

Kalimehtar commented 10 years ago

Maybe then gtk_parse_args. It doesn't depend on display availability, but has inout arg.

hying-caritas commented 10 years ago

Tried gtk_parse_args, but it appears the result (via in-out parameters) of the second invoking is different from the first one.

Kalimehtar commented 10 years ago

I think, that very first run is setting GTK init state (except display). You may check result of second invoking with third, fourth and so on ...

hying-caritas commented 10 years ago

argv is always: ("test" "--display" ":100000.0"). Result of first time is: ("test"), from second time on, it is ("test" "--display" ":100000.0"). But the first time result is my intended one.