Commit 30cc7919 authored by Vladimir Bashkirtsev's avatar Vladimir Bashkirtsev

Fixed unittest_osdscrub - tm structure should be zeroed before use

parent 551b4cd9
diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts
--- ceph-14.2.2/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts 2019-07-18 00:42:36.000000000 +0930 --- ceph-14.2.2/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts 2019-07-18 00:42:36.000000000 +0930
+++ ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts 2019-07-21 13:29:59.386543309 +0930 +++ ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable/table/table.component.spec.ts 2019-09-23 21:09:51.817960850 +0930
@@ -87,13 +87,6 @@ @@ -87,13 +87,6 @@
expect(component.userConfig.limit).toBe(1); expect(component.userConfig.limit).toBe(1);
}); });
...@@ -17,7 +17,7 @@ diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable ...@@ -17,7 +17,7 @@ diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/frontend/src/app/shared/datatable
component.identifier = 'x'; component.identifier = 'x';
diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/tests/test_task.py ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/tests/test_task.py diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/tests/test_task.py ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/tests/test_task.py
--- ceph-14.2.2/src/pybind/mgr/dashboard/tests/test_task.py 2019-07-18 00:42:36.000000000 +0930 --- ceph-14.2.2/src/pybind/mgr/dashboard/tests/test_task.py 2019-07-18 00:42:36.000000000 +0930
+++ ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/tests/test_task.py 2019-07-21 13:18:04.746160870 +0930 +++ ceph-14.2.2-fix_tests/src/pybind/mgr/dashboard/tests/test_task.py 2019-09-23 21:09:51.818960852 +0930
@@ -177,57 +177,6 @@ @@ -177,57 +177,6 @@
self.assertEqual(str(fn_t[0].exception), "Task Unexpected Exception") self.assertEqual(str(fn_t[0].exception), "Task Unexpected Exception")
self.assertEqual(fn_t[0].progress, 70) self.assertEqual(fn_t[0].progress, 70)
...@@ -125,7 +125,7 @@ diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/tests/test_task.py ceph-14.2.2-fi ...@@ -125,7 +125,7 @@ diff -uNr ceph-14.2.2/src/pybind/mgr/dashboard/tests/test_task.py ceph-14.2.2-fi
state, result = task1.run('test9/task1') state, result = task1.run('test9/task1')
diff -uNr ceph-14.2.2/src/test/CMakeLists.txt ceph-14.2.2-fix_tests/src/test/CMakeLists.txt diff -uNr ceph-14.2.2/src/test/CMakeLists.txt ceph-14.2.2-fix_tests/src/test/CMakeLists.txt
--- ceph-14.2.2/src/test/CMakeLists.txt 2019-07-18 00:42:36.000000000 +0930 --- ceph-14.2.2/src/test/CMakeLists.txt 2019-07-18 00:42:36.000000000 +0930
+++ ceph-14.2.2-fix_tests/src/test/CMakeLists.txt 2019-07-21 13:18:04.757160907 +0930 +++ ceph-14.2.2-fix_tests/src/test/CMakeLists.txt 2019-09-23 21:09:51.818960852 +0930
@@ -528,6 +528,7 @@ @@ -528,6 +528,7 @@
if(WITH_RBD) if(WITH_RBD)
...@@ -136,7 +136,7 @@ diff -uNr ceph-14.2.2/src/test/CMakeLists.txt ceph-14.2.2-fix_tests/src/test/CMa ...@@ -136,7 +136,7 @@ diff -uNr ceph-14.2.2/src/test/CMakeLists.txt ceph-14.2.2-fix_tests/src/test/CMa
endif(FREEBSD) endif(FREEBSD)
diff -uNr ceph-14.2.2/src/test/mgr/CMakeLists.txt ceph-14.2.2-fix_tests/src/test/mgr/CMakeLists.txt diff -uNr ceph-14.2.2/src/test/mgr/CMakeLists.txt ceph-14.2.2-fix_tests/src/test/mgr/CMakeLists.txt
--- ceph-14.2.2/src/test/mgr/CMakeLists.txt 2019-07-18 00:42:36.000000000 +0930 --- ceph-14.2.2/src/test/mgr/CMakeLists.txt 2019-07-18 00:42:36.000000000 +0930
+++ ceph-14.2.2-fix_tests/src/test/mgr/CMakeLists.txt 2019-07-21 13:18:04.759160913 +0930 +++ ceph-14.2.2-fix_tests/src/test/mgr/CMakeLists.txt 2019-09-23 21:09:51.818960852 +0930
@@ -2,6 +2,7 @@ @@ -2,6 +2,7 @@
if(WITH_MGR_DASHBOARD_FRONTEND) if(WITH_MGR_DASHBOARD_FRONTEND)
if(NOT CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|AARCH64|arm|ARM") if(NOT CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|AARCH64|arm|ARM")
...@@ -145,3 +145,15 @@ diff -uNr ceph-14.2.2/src/test/mgr/CMakeLists.txt ceph-14.2.2-fix_tests/src/test ...@@ -145,3 +145,15 @@ diff -uNr ceph-14.2.2/src/test/mgr/CMakeLists.txt ceph-14.2.2-fix_tests/src/test
endif(NOT CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|AARCH64|arm|ARM") endif(NOT CMAKE_SYSTEM_PROCESSOR MATCHES "aarch64|AARCH64|arm|ARM")
add_ceph_test(mgr-dashboard-smoke.sh ${CMAKE_CURRENT_SOURCE_DIR}/mgr-dashboard-smoke.sh) add_ceph_test(mgr-dashboard-smoke.sh ${CMAKE_CURRENT_SOURCE_DIR}/mgr-dashboard-smoke.sh)
diff -uNr ceph-14.2.2/src/test/osd/TestOSDScrub.cc ceph-14.2.2-fix_tests/src/test/osd/TestOSDScrub.cc
--- ceph-14.2.2/src/test/osd/TestOSDScrub.cc 2019-07-18 00:42:36.000000000 +0930
+++ ceph-14.2.2-fix_tests/src/test/osd/TestOSDScrub.cc 2019-09-23 21:10:28.452044891 +0930
@@ -70,7 +70,7 @@
g_ceph_context->_conf.set_val("osd_scrub_begin_hour", "0");
g_ceph_context->_conf.set_val("osd_scrub_end_hour", "24");
g_ceph_context->_conf.apply_changes(nullptr);
- tm tm;
+ tm tm = {0};
strptime("2015-01-16 12:05:13", "%Y-%m-%d %H:%M:%S", &tm);
utime_t now = utime_t(mktime(&tm), 0);
bool ret = osd->scrub_time_permit(now);
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment