Test setf value for variant, nil variant & operator conversion,
Mon May 11 16:18:40 CEST 2009 Tobias Rautenkranz <tobias@rautenkranz.ch>
* Test setf value for variant, nil variant & operator conversion,
hunk ./qt.tests.mbd 12
- ("src" module
- (:components "package"
- ("tests" (:needs "package"))
- ("qbytearray" (:needs "tests"))
- ("qstring" (:needs "tests"))
- ("overload" (:needs "tests"))
- ("gc" (:needs "tests"))
- ("variant" (:needs "tests"))
- ("application" (:needs "tests"))
- ("signal-slot" (:needs "tests"))
- ("operators" (:needs "tests"))
- ("thread" (:needs "tests"))
- ("properties" (:needs "tests"))
- ("click" (:needs "tests"))))))
+ ("src" module
+ (:components
+ "package"
+ ("tests" (:needs "package"))
+ ("qbytearray" (:needs "tests"))
+ ("qstring" (:needs "tests"))
+ ("overload" (:needs "tests"))
+ ("gc" (:needs "tests"))
+ ("variant" (:needs "tests"))
+ ("application" (:needs "tests"))
+ ("signal-slot" (:needs "tests"))
+ ("operators" (:needs "tests"))
+ ("thread" (:needs "tests"))
+ ("properties" (:needs "tests"))
+ ("click" (:needs "tests"))))))
hunk ./src/variant.lisp 26
+(5am:test variant-color
+ "The C++ overload resolution for QColor:operator QVariant()."
+ (let* ((color (make-instance 'qt:color))
+ (variant1 (qt:make-variant color))
+ (variant2 (qt:make-variant color)))
+ (5am:is (eq t (cxx:= variant1 variant2)))))
+ [_$_]
+(5am:test nil-variant
+ "Make a nil variant."
+ (5am:is (eq nil (qt:variant-boundp (qt:make-variant)))))
+
+(5am:test setf-variant-value
+ "Set a qt:variant."
+ (let ((variant (qt:make-variant)))
+ (5am:is (= 1 (setf (qt:value variant) 1)))
+ (5am:is (= 1 (qt:value variant)))))
+