glib/gio/tests
Nelson Benítez León 32a9b88b20 gio/tests: Add testcase for bug 787731
Add testcase for function g_file_query_filesystem_info()
reporting outdated info for "filesystem::readonly" attribute
when said attribute was different in a previous mounted
partition in the same device (as GIO maintains a mounts cache
per 'st_dev' stat() member).

To trigger a mount operation, testcase uses program 'bindfs'
instead of 'mount --bind' as bindfs does not require root
privileges. And 'fusermount -u' command is used to unmount said
bindfs mount.

As a reference in Fedora, 'bindfs' is installed from 'bindfs'
package and 'fusermount' from 'fuse' package (this one is installed
by default as being part of 'System Tools' group).

The test creates a directory with a file in it, then mounts it
readonly over another directory (the mountpoint), it then checks
that g_file_query_filesystem_info() for the file in it indeed reports
"filesystem::readonly" as TRUE. Then unmounts and mounts again this
time rw (not readonly), it then checks again if g_file_query_filesystem_info()
is reporting "filesystem::readonly" as TRUE, if that's the case, it
confirms the bug by opening said file in write mode.

Testcase is only added for Unix builds.

https://bugzilla.gnome.org/show_bug.cgi?id=787731
2017-09-22 20:28:44 +05:00
..
cert-tests Add certificate chain construction test 2015-08-29 08:43:29 -05:00
de/LC_MESSAGES meson add missing gio/tests subdirectory/file 2017-07-13 19:03:39 -04:00
desktop-files tests: add testcase for {Only,Not}ShowIn 2014-05-08 16:19:56 -04:00
gdbus-object-manager-example meson: fix remaining wrong #include's for gdbus_codegen files 2017-07-13 22:22:16 -04:00
modules Use "-module" when compiling loadable modules 2017-08-03 12:28:10 +01:00
schema-tests gsettings: add test for repeated <summary> errors 2015-04-08 22:35:35 -04:00
services Adding test coverage for GTestDBus activating in-tree services. 2012-12-28 21:28:28 -05:00
thumbnails tests: Add tests for the thumbnail verification code in GIO 2013-10-24 13:55:33 -04:00
x-content Add tests for x-content type sniffing 2014-01-01 17:59:20 -05:00
.gitignore gio: tests: rename generated giotypefunc.c to giotypefuncs.inc 2017-07-13 19:03:39 -04:00
actions.c Allow property actions to invert booleans 2015-06-10 21:59:28 -04:00
appinfo-test2.desktop Cleanups 2010-07-05 00:56:12 -04:00
appinfo-test-actions.desktop Add missing file 2013-07-11 13:49:20 -04:00
appinfo-test-gnome.desktop Add some more appinfo tests 2010-07-04 20:51:06 -04:00
appinfo-test-notgnome.desktop Add some more appinfo tests 2010-07-04 20:51:06 -04:00
appinfo-test.c Fix up the appinfo test 2013-11-23 22:21:29 -05:00
appinfo-test.desktop Improve GAppInfo test coverage 2012-08-19 02:23:32 -04:00
appinfo.c meson: gio/tests: add more gio tests 2017-07-13 19:03:39 -04:00
appmonitor.c tests: Add temporary working directory for appmonitor test 2017-08-23 11:26:57 +01:00
apps.c apps test: add new "monitor" subcommand 2014-09-09 14:11:38 -04:00
async-close-output-stream.c gtestutils: add g_assert_cmpmem() 2015-08-31 13:59:48 -04:00
async-splice-output-stream.c tests: Add testcases for g_output_stream_splice_async() 2013-09-29 17:48:40 -04:00
autoptr.c tests: Add many autoptr tests 2015-02-23 10:40:40 -05:00
basic-application.c Avoid a compiler warning 2014-01-01 22:01:15 -05:00
buffered-input-stream.c gio/tests: add some more async stream tests 2013-01-16 10:17:15 -05:00
buffered-output-stream.c Update tests for new truncate behavior 2013-12-15 21:07:12 -05:00
cancellable.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
contenttype.c xdgmime: fix special case for mime_type_subclass 2017-05-16 11:16:41 +01:00
contexts.c GContextSpecificGroup: add testcase 2016-04-26 15:20:16 +02:00
converter-stream.c gtestutils: add g_assert_cmpmem() 2015-08-31 13:59:48 -04:00
credentials.c gcredentials: add NetBSD support 2014-06-28 14:06:36 -04:00
data-input-stream.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
data-output-stream.c Update tests for new truncate behavior 2013-12-15 21:07:12 -05:00
dbus-appinfo.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
dbus-launch.c Consistently save errno immediately after the operation setting it 2017-08-03 10:21:13 +01:00
de.po Merge GSettings tests 2010-04-17 01:48:05 -04:00
defaultvalue.c gio: tests: rename generated giotypefunc.c to giotypefuncs.inc 2017-07-13 19:03:39 -04:00
desktop-app-info.c meson: gio/tests: add more gio tests 2017-07-13 19:03:39 -04:00
echo-server.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
enums.xml.template GSettings: major refactor. Add enums, range. 2010-06-16 18:17:53 -04:00
file.c introspection: use (nullable) or (optional) instead of (allow-none) 2016-11-22 14:14:37 -08:00
fileattributematcher.c Simplify fileattributematcher tests a bit 2014-01-01 17:59:20 -05:00
filter-cat.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
filter-streams.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
g-file-info-filesystem-readonly.c gio/tests: Add testcase for bug 787731 2017-09-22 20:28:44 +05:00
g-file-info.c Improve GFileAttributeMatcher test coverage 2013-06-02 01:43:13 -04:00
g-file.c tests: replace most g_print() with g_printerr() 2015-05-11 20:24:56 +01:00
g-icon.c g-icon: Fix memory leak in test 2013-11-11 07:11:29 +01:00
gapplication-example-actions.c Don't use deprecated GApplication api in examples 2011-12-08 18:05:15 -05:00
gapplication-example-cmdline2.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gapplication-example-cmdline3.c e G_SOURCE_CONTINUE/REMOVE internally 2012-01-25 16:15:18 -05:00
gapplication-example-cmdline.c Tweak GApplication docs 2010-11-02 23:02:05 -04:00
gapplication-example-dbushooks.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gapplication-example-open.c Tweak GApplication docs 2010-11-02 23:02:05 -04:00
gapplication.c Add some more cases to the app-id unit tests 2017-03-05 13:11:52 -05:00
gdbus-addresses.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-auth.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-bz627724.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-close-pending.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-connection-flush-helper.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-connection-flush.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-connection-loss.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-connection-slow.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-connection.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-daemon.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-error.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-example-export.c Drop trailing semi-colon from G_DEFINE_ macro 2017-04-10 10:38:31 +01:00
gdbus-example-objectmanager-client.c Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
gdbus-example-objectmanager-server.c Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
gdbus-example-own-name.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-peer.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-proxy-subclass.c Drop trailing semi-colon from G_DEFINE_ macro 2017-04-10 10:38:31 +01:00
gdbus-example-server.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-subtree.c Use 'dumb quotes' rather than `really dumb quotes' 2013-05-21 11:23:22 -03:00
gdbus-example-unix-fd-client.c gdbus-example-unix-fd-client: avoid strftime %c specifier 2016-08-15 14:04:43 +01:00
gdbus-example-watch-name.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-example-watch-proxy.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
gdbus-exit-on-close.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-export.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-introspection.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-message.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-names.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-non-socket.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-overflow.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-peer-object-manager.c Consistently save errno immediately after the operation setting it 2017-08-03 10:21:13 +01:00
gdbus-peer.c Consistently save errno immediately after the operation setting it 2017-08-03 10:21:13 +01:00
gdbus-proxy-threads.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-proxy-well-known-name.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-proxy.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-serialization.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-sessionbus.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-sessionbus.h gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-test-codegen.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-test-fixture.c Rework the build system for a new tests approach 2013-05-31 23:12:15 -04:00
gdbus-tests.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-tests.h gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-testserver.c Add a C version of gdbus-testserver.py 2013-01-03 13:14:26 -05:00
gdbus-threading.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gdbus-unix-addresses.c Consistently save errno immediately after the operation setting it 2017-08-03 10:21:13 +01:00
gengiotypefuncs.py meson: gio/tests: add more missing tests 2017-07-13 19:03:39 -04:00
gio-du.c win32: Replace usage of __wgetmainargs() 2015-07-23 04:22:59 -04:00
giomodule.c giomodule test: fix again 2014-01-13 16:12:31 -05:00
glistmodel.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gmenumodel.c Drop trailing semi-colon from G_DEFINE_ macro 2017-04-10 10:38:31 +01:00
gnotification-server.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gnotification-server.h gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gnotification.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gschema-compile.c tests: Fix gschema-compile test for translatable string changes 2017-08-03 16:32:42 +01:00
gsettings.c meson: gio/tests: add more gio tests 2017-07-13 19:03:39 -04:00
gsubprocess-testprog.c Consistently save errno immediately after the operation setting it 2017-08-03 10:21:13 +01:00
gsubprocess.c tests: Fix some leaks and double-frees in the GSubprocess tests 2017-08-23 11:37:32 +01:00
gtesttlsbackend.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gtesttlsbackend.h gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gtlsconsoleinteraction.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
gtlsconsoleinteraction.h gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
httpd.c Avoid setting unused variables (-Wself-assign) 2017-09-11 22:14:18 +01:00
inet-address.c Fix gio/tests/inet-address on OS X 2016-07-11 17:42:41 -04:00
io-stream.c tests: add GSimpleIOStream async close tests 2015-02-17 16:27:46 -05:00
live-g-file.c tests: replace most g_print() with g_printerr() 2015-05-11 20:24:56 +01:00
live-g-file.txt Revert "Move gio tests from gio/tests/ to tests/gio/" 2009-07-05 22:49:24 -04:00
Makefile.am gio/tests: Add testcase for bug 787731 2017-09-22 20:28:44 +05:00
memory-input-stream.c Improve GMemoryInputStream test coverage 2013-06-02 01:44:49 -04:00
memory-output-stream.c Expand the truncate tests 2013-12-15 21:07:12 -05:00
meson.build gio/tests: Add testcase for bug 787731 2017-09-22 20:28:44 +05:00
mimeapps.c tests: use mimeapps.list over defaults.list 2014-04-15 11:36:39 -04:00
monitor.c tests: Add temporary working directory for monitor test 2017-08-23 11:26:57 +01:00
network-address.c gsocketconnectable: Add a to_string() virtual method 2015-10-13 15:42:14 +01:00
network-monitor.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
org.gtk.schemasourcecheck.gschema.xml Add test case and fix some bugs 2011-11-17 14:03:39 +00:00
org.gtk.test.dbusappinfo.desktop Make a test desktop file a little less invalid 2013-07-14 11:36:45 -04:00
org.gtk.test.gschema.xml.orig Add a test for dictionaries in settings 2016-09-26 06:27:12 -04:00
permission.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
pollable.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
proxy-test.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
proxy.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
readwrite.c gtestutils: add g_assert_cmpmem() 2015-08-31 13:59:48 -04:00
resolver.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
resourceplugin.c visibility: Use a separate CFLAGS variable 2013-01-14 23:31:59 -05:00
resources.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
send-data.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
simple-async-result.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
simple-proxy.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
sleepy-stream.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
socket-address.c gsocketconnectable: Add a to_string() virtual method 2015-10-13 15:42:14 +01:00
socket-client.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
socket-common.c gio/tests/socket-common.c: add a missing #ifdef G_OS_UNIX 2012-02-03 12:58:53 -05:00
socket-listener.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
socket-server.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
socket-service.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
socket.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
srvtarget.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
stream-rw_all.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
task.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
test1.txt Add tests for GResource 2012-01-13 17:12:53 +01:00
test2.gresource.xml Add tests for GResource 2012-01-13 17:12:53 +01:00
test2.txt Add tests for GResource 2012-01-13 17:12:53 +01:00
test3.gresource.xml Add tests for GResource 2012-01-13 17:12:53 +01:00
test3.txt Add tests for GResource 2012-01-13 17:12:53 +01:00
test4.gresource.xml Add tests for GResource 2012-01-13 17:12:53 +01:00
test-codegen.xml gdbus-codegen: Update tests for new inheritance-semantics for Since 2012-10-03 11:23:04 -04:00
test-io-stream.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
test-io-stream.h gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
test-pipe-unix.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
test-pipe-unix.h gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
test.gresource.xml glib-compile-resources: correct resource compiler dependency for generated files 2016-06-04 08:24:22 -04:00
testenum.h Bug 622124 - implement flags for GSettings 2010-07-01 19:06:02 -04:00
testfilemonitor.c Code cleanup 2015-08-21 00:43:54 -04:00
thumbnail-verification.c Fix the thumbnail-verification Test 2015-04-22 18:56:50 +08:00
tls-certificate.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
tls-interaction.c gio/tests/: LGPLv2+ -> LGPLv2.1+ 2017-05-29 19:53:34 +02:00
unix-fd.c Add gnetworking.h 2012-12-12 15:20:22 +01:00
unix-streams.c Improve unix stream test coverage 2013-06-02 01:47:19 -04:00
vfs.c vfs: Fix return value of get_supported_uri_schemes() 2016-06-28 15:57:49 +02:00
volumemonitor.c Remove g_type_init() calls 2012-10-16 09:39:24 -04:00
win32-streams.c Fix tests to compile again - add missing headers to W32, call correct process-id-getting function 2014-08-02 12:41:14 +00:00