summaryrefslogtreecommitdiffstats
path: root/libreport/src/report-python/test_dd_create
diff options
context:
space:
mode:
Diffstat (limited to 'libreport/src/report-python/test_dd_create')
-rwxr-xr-xlibreport/src/report-python/test_dd_create25
1 files changed, 25 insertions, 0 deletions
diff --git a/libreport/src/report-python/test_dd_create b/libreport/src/report-python/test_dd_create
new file mode 100755
index 00000000..4da29b11
--- /dev/null
+++ b/libreport/src/report-python/test_dd_create
@@ -0,0 +1,25 @@
+#!/usr/bin/python
+
+from report import *
+
+dd = dd_create("testdir")
+print dd
+
+if dd:
+ print "dd is nonzero"
+else:
+ print "dd is zero"
+
+print "name:", dd.name
+print "closing"
+dd.close()
+
+if dd:
+ print "dd is nonzero"
+else:
+ print "dd is zero"
+
+# Should fail here
+dd.name = "qwe"
+
+print "Done"