Tizen 2.0 Release
[external/module-init-tools.git] / tests / test-insmod / 03options.sh
1 #! /bin/sh
2
3 SIZE=`wc -c < tests/test-insmod/02simple.sh`
4 # Old options are ignored.
5 [ "`insmod -p tests/test-insmod/02simple.sh`" = "INIT_MODULE: $SIZE " ]
6 [ "`insmod -s tests/test-insmod/02simple.sh`" = "INIT_MODULE: $SIZE " ]
7 [ "`insmod -f tests/test-insmod/02simple.sh`" = "INIT_MODULE: $SIZE " ]
8 [ "`insmod -p -f -s tests/test-insmod/02simple.sh`" = "INIT_MODULE: $SIZE " ]
9
10 # --version and -v
11 VERSION=`grep ^VERSION tests/build/Makefile | sed 's/.*=[       ]*//'`
12 [ "`insmod -V`" = "module-init-tools version $VERSION" ]
13 [ "`insmod --version`" = "module-init-tools version $VERSION" ]
14
15 # Don't try to quote or anything: we're not smart enough.
16 [ "`insmod tests/test-insmod/02simple.sh 'foo="baz bar"'`" = "INIT_MODULE: $SIZE foo=\"baz bar\" " ]