equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). |
2 * Copyright (c) 2005 Nokia Corporation and/or its subsidiary(-ies). |
3 * All rights reserved. |
3 * All rights reserved. |
4 * This component and the accompanying materials are made available |
4 * This component and the accompanying materials are made available |
5 * under the terms of the License "Symbian Foundation License v1.0" |
5 * under the terms of "Eclipse Public License v1.0" |
6 * which accompanies this distribution, and is available |
6 * which accompanies this distribution, and is available |
7 * at the URL "http://www.symbianfoundation.org/legal/sfl-v10.html". |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
8 * |
8 * |
9 * Initial Contributors: |
9 * Initial Contributors: |
10 * Nokia Corporation - initial contribution. |
10 * Nokia Corporation - initial contribution. |
11 * |
11 * |
12 * Contributors: |
12 * Contributors: |
30 const TInt KNoPreparePartial = 40; |
30 const TInt KNoPreparePartial = 40; |
31 _LIT(KTakePreparedPartialErr, "Method TakePreparedPartialLandmarksL doesn't leave with KErrNotFound"); |
31 _LIT(KTakePreparedPartialErr, "Method TakePreparedPartialLandmarksL doesn't leave with KErrNotFound"); |
32 _LIT(KNoPreparedPartialErr, "Method TakePreparedPartialLandmarksL returns incorrect no. landmarks"); |
32 _LIT(KNoPreparedPartialErr, "Method TakePreparedPartialLandmarksL returns incorrect no. landmarks"); |
33 _LIT(KNoPreparedPartialErr2, "Method TakePreparedPartialLandmarksL returns incorrect landmarks"); |
33 _LIT(KNoPreparedPartialErr2, "Method TakePreparedPartialLandmarksL returns incorrect landmarks"); |
34 |
34 |
|
35 _LIT(KTp18DbFile, "TP18Test.ldb"); |
|
36 _LIT(KTp18DbFile1, "TP18Test1.ldb"); |
|
37 |
35 // ================= MEMBER FUNCTIONS ======================= |
38 // ================= MEMBER FUNCTIONS ======================= |
36 |
39 |
37 |
40 |
38 // --------------------------------------------------------- |
41 // --------------------------------------------------------- |
39 // CPosTp10::CloseTest |
42 // CPosTp10::CloseTest |
64 // --------------------------------------------------------- |
67 // --------------------------------------------------------- |
65 // |
68 // |
66 void CPosTp18::StartL() |
69 void CPosTp18::StartL() |
67 { |
70 { |
68 _LIT(KNotPartialErr, "Landmark is not a partial landmark"); |
71 _LIT(KNotPartialErr, "Landmark is not a partial landmark"); |
69 |
72 CopyTestDbFileL(KTp18DbFile); |
70 iDatabase = UseGeneratedDbFileL(); |
73 iDatabase = CPosLandmarkDatabase::OpenL(KTp18DbFile); |
71 |
74 |
72 if (iDatabase->IsInitializingNeeded()) |
75 if (iDatabase->IsInitializingNeeded()) |
73 { |
76 { |
74 ExecuteAndDeleteLD(iDatabase->InitializeL()); |
77 ExecuteAndDeleteLD(iDatabase->InitializeL()); |
75 } |
78 } |
412 |
415 |
413 // Test not setting any attributes with SetRequestedAttributes, |
416 // Test not setting any attributes with SetRequestedAttributes, |
414 // should only return empty landmarks |
417 // should only return empty landmarks |
415 delete iDatabase; |
418 delete iDatabase; |
416 iDatabase = NULL; |
419 iDatabase = NULL; |
417 iDatabase = UseGeneratedDbFileL(); |
420 CopyTestDbFileL(KTp18DbFile1); |
|
421 iDatabase = CPosLandmarkDatabase::OpenL(KTp18DbFile1); |
418 |
422 |
419 if (iDatabase->IsInitializingNeeded()) ExecuteAndDeleteLD(iDatabase->InitializeL()); |
423 if (iDatabase->IsInitializingNeeded()) ExecuteAndDeleteLD(iDatabase->InitializeL()); |
420 |
424 |
421 CleanupClosePushL(ids); |
425 CleanupClosePushL(ids); |
422 ids.Append(1); |
426 ids.Append(1); |