+++ /dev/null
-
-#include <iostream>
-#include <fstream>
-#include <list>
-#include <string>
-
-#include "zypp/base/Logger.h"
-#include "zypp/base/Exception.h"
-#include "zypp2/Lazy.h"
-#include "zypp/TmpPath.h"
-
-#include <boost/test/unit_test.hpp>
-
-using boost::unit_test::test_suite;
-using boost::unit_test::test_case;
-
-using namespace std;
-using namespace zypp;
-
-char descfile[]=
-{
- 0x3d,0x56,0x65,0x72,0x3a,0x20,0x32,0x2e,0x30,0x0a,0x23,0x23,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x0a,0x3d,0x50,0x6b,0x67,0x3a,0x20,0x33,0x64,0x64,0x69,0x61,0x67,
- 0x20,0x30,0x2e,0x37,0x33,0x38,0x20,0x32,0x35,0x20,0x69,0x35,0x38,
- 0x36,0x0a,0x3d,0x53,0x75,0x6d,0x3a,0x20,0x41,0x20,0x54,0x6f,0x6f,
- 0x6c,0x20,0x74,0x6f,0x20,0x56,0x65,0x72,0x69,0x66,0x79,0x20,0x74,
- 0x68,0x65,0x20,0x33,0x44,0x20,0x43,0x6f,0x6e,0x66,0x69,0x67,0x75,
- 0x72,0x61,0x74,0x69,0x6f,0x6e,0x0a,0x2b,0x44,0x65,0x73,0x3a,0x0a,
- 0x3c,0x21,0x2d,0x2d,0x20,0x44,0x54,0x3a,0x52,0x69,0x63,0x68,0x20,
- 0x2d,0x2d,0x3e,0x0a,0x3c,0x70,0x3e,0x57,0x69,0x74,0x68,0x20,0x33,
- 0x44,0x64,0x69,0x61,0x67,0x20,0x79,0x6f,0x75,0x20,0x63,0x61,0x6e,
- 0x20,0x76,0x65,0x72,0x69,0x66,0x79,0x20,0x74,0x68,0x65,0x20,0x33,
- 0x44,0x20,0x63,0x6f,0x6e,0x66,0x69,0x67,0x75,0x72,0x61,0x74,0x69,
- 0x6f,0x6e,0x2e,0x0a,0x3c,0x2f,0x70,0x3e,0x0a,0x2d,0x44,0x65,0x73,
- 0x3a,0x0a,0x23,0x23,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x0a,0x3d,0x50,0x6b,0x67,0x3a,0x20,0x33,
- 0x64,0x64,0x69,0x61,0x67,0x2d,0x64,0x65,0x62,0x75,0x67,0x69,0x6e,
- 0x66,0x6f,0x20,0x30,0x2e,0x37,0x33,0x38,0x20,0x32,0x35,0x20,0x69,
- 0x35,0x38,0x36,0x0a,0x3d,0x53,0x75,0x6d,0x3a,0x20,0x41,0x20,0x54,
- 0x6f,0x6f,0x6c,0x20,0x74,0x6f,0x20,0x56,0x65,0x72,0x69,0x66,0x79,
- 0x20,0x74,0x68,0x65,0x20,0x33,0x44,0x20,0x43,0x6f,0x6e,0x66,0x69,
- 0x67,0x75,0x72,0x61,0x74,0x69,0x6f,0x6e,0x0a,0x2b,0x44,0x65,0x73,
- 0x3a,0x0a,0x3c,0x21,0x2d,0x2d,0x20,0x44,0x54,0x3a,0x52,0x69,0x63,
- 0x68,0x20,0x2d,0x2d,0x3e,0x0a,0x3c,0x70,0x3e,0x57,0x69,0x74,0x68,
- 0x20,0x33,0x44,0x64,0x69,0x61,0x67,0x20,0x79,0x6f,0x75,0x20,0x63,
- 0x61,0x6e,0x20,0x76,0x65,0x72,0x69,0x66,0x79,0x20,0x74,0x68,0x65,
- 0x20,0x33,0x44,0x20,0x63,0x6f,0x6e,0x66,0x69,0x67,0x75,0x72,0x61,
- 0x74,0x69,0x6f,0x6e,0x2e,0x0a,0x3c,0x2f,0x70,0x3e,0x0a,0x2d,0x44,
- 0x65,0x73,0x3a,0x0a,0x23,0x23,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x0a,0x3d,0x50,0x6b,0x67,0x3a,
- 0x20,0x33,0x64,0x74,0x6f,0x33,0x64,0x20,0x33,0x2e,0x35,0x20,0x35,
- 0x31,0x20,0x69,0x35,0x38,0x36,0x0a,0x3d,0x53,0x75,0x6d,0x3a,0x20,
- 0x43,0x6f,0x6e,0x76,0x65,0x72,0x74,0x65,0x72,0x20,0x66,0x6f,0x72,
- 0x20,0x53,0x65,0x76,0x65,0x72,0x61,0x6c,0x20,0x33,0x2d,0x44,0x69,
- 0x6d,0x65,0x6e,0x73,0x69,0x6f,0x6e,0x61,0x6c,0x20,0x4f,0x62,0x6a,
- 0x65,0x63,0x74,0x20,0x46,0x69,0x6c,0x65,0x20,0x46,0x6f,0x72,0x6d,
- 0x61,0x74,0x73,0x0a,0x2b,0x44,0x65,0x73,0x3a,0x0a,0x3c,0x21,0x2d,
- 0x2d,0x20,0x44,0x54,0x3a,0x52,0x69,0x63,0x68,0x20,0x2d,0x2d,0x3e,
- 0x0a,0x3c,0x70,0x3e,0x33,0x64,0x74,0x6f,0x33,0x64,0x20,0x69,0x73,
- 0x20,0x61,0x20,0x63,0x6f,0x6d,0x6d,0x61,0x6e,0x64,0x2d,0x6c,0x69,
- 0x6e,0x65,0x20,0x74,0x6f,0x6f,0x6c,0x20,0x61,0x62,0x6c,0x65,0x20,
- 0x74,0x6f,0x20,0x63,0x6f,0x6e,0x76,0x65,0x72,0x74,0x20,0x6f,0x62,
- 0x6a,0x65,0x63,0x74,0x73,0x20,0x69,0x6e,0x20,0x33,0x44,0x20,0x53,
- 0x74,0x75,0x64,0x69,0x6f,0x2c,0x20,0x49,0x6d,0x61,0x67,0x69,0x6e,
- 0x65,0x0a,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,0x20,0x4c,0x69,0x67,
- 0x68,0x74,0x57,0x61,0x76,0x65,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,
- 0x2c,0x20,0x41,0x75,0x74,0x6f,0x43,0x61,0x64,0x20,0x4f,0x62,0x6a,
- 0x65,0x63,0x74,0x2c,0x20,0x50,0x6f,0x76,0x72,0x61,0x79,0x20,0x42,
- 0x69,0x6e,0x61,0x72,0x79,0x2c,0x20,0x61,0x6e,0x64,0x20,0x57,0x61,
- 0x76,0x65,0x46,0x72,0x6f,0x6e,0x74,0x20,0x66,0x6f,0x72,0x6d,0x61,
- 0x74,0x73,0x20,0x74,0x6f,0x0a,0x4d,0x6f,0x72,0x61,0x79,0x2f,0x50,
- 0x6f,0x76,0x72,0x61,0x79,0x2c,0x20,0x4d,0x6f,0x72,0x61,0x79,0x2f,
- 0x50,0x6f,0x6c,0x79,0x72,0x61,0x79,0x2c,0x20,0x33,0x44,0x53,0x74,
- 0x75,0x64,0x69,0x6f,0x2c,0x20,0x48,0x69,0x67,0x68,0x4c,0x69,0x67,
- 0x68,0x74,0x2c,0x20,0x52,0x65,0x61,0x6c,0x33,0x44,0x20,0x4d,0x61,
- 0x63,0x72,0x6f,0x2c,0x20,0x33,0x44,0x20,0x53,0x74,0x75,0x64,0x69,
- 0x6f,0x20,0x42,0x69,0x6e,0x61,0x72,0x79,0x2c,0x0a,0x4d,0x6f,0x72,
- 0x61,0x79,0x2f,0x50,0x6f,0x76,0x72,0x61,0x79,0x20,0x28,0x57,0x69,
- 0x72,0x65,0x29,0x2c,0x20,0x4d,0x6f,0x72,0x61,0x79,0x2f,0x50,0x6f,
- 0x76,0x72,0x61,0x79,0x20,0x28,0x42,0x6c,0x6f,0x62,0x20,0x57,0x69,
- 0x72,0x65,0x29,0x2c,0x20,0x49,0x6d,0x61,0x67,0x69,0x6e,0x65,0x20,
- 0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,0x20,0x52,0x65,0x6e,0x64,0x65,
- 0x72,0x57,0x61,0x72,0x65,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,
- 0x0a,0x56,0x52,0x4d,0x4c,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,
- 0x20,0x44,0x58,0x46,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,0x20,
- 0x4c,0x69,0x67,0x68,0x74,0x77,0x61,0x76,0x65,0x20,0x4f,0x62,0x6a,
- 0x65,0x63,0x74,0x2c,0x20,0x44,0x69,0x72,0x65,0x63,0x74,0x20,0x58,
- 0x20,0x28,0x4d,0x69,0x63,0x72,0x6f,0x73,0x6f,0x66,0x74,0x29,0x2c,
- 0x20,0x52,0x65,0x61,0x6c,0x33,0x44,0x20,0x4f,0x62,0x6a,0x65,0x63,
- 0x74,0x2c,0x0a,0x4f,0x70,0x65,0x6e,0x47,0x4c,0x20,0x43,0x20,0x73,
- 0x6f,0x75,0x72,0x63,0x65,0x2c,0x20,0x6f,0x72,0x20,0x57,0x61,0x76,
- 0x65,0x46,0x72,0x6f,0x6e,0x74,0x20,0x66,0x6f,0x72,0x6d,0x61,0x74,
- 0x2e,0x0a,0x3c,0x2f,0x70,0x3e,0x0a,0x2d,0x44,0x65,0x73,0x3a,0x0a,
- 0x23,0x23,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x0a,0x3d,0x50,0x6b,0x67,0x3a,0x20,0x33,0x64,0x74,
- 0x6f,0x33,0x64,0x2d,0x64,0x65,0x62,0x75,0x67,0x69,0x6e,0x66,0x6f,
- 0x20,0x33,0x2e,0x35,0x20,0x35,0x31,0x20,0x69,0x35,0x38,0x36,0x0a,
- 0x3d,0x53,0x75,0x6d,0x3a,0x20,0x43,0x6f,0x6e,0x76,0x65,0x72,0x74,
- 0x65,0x72,0x20,0x66,0x6f,0x72,0x20,0x53,0x65,0x76,0x65,0x72,0x61,
- 0x6c,0x20,0x33,0x2d,0x44,0x69,0x6d,0x65,0x6e,0x73,0x69,0x6f,0x6e,
- 0x61,0x6c,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x20,0x46,0x69,0x6c,
- 0x65,0x20,0x46,0x6f,0x72,0x6d,0x61,0x74,0x73,0x0a,0x2b,0x44,0x65,
- 0x73,0x3a,0x0a,0x3c,0x21,0x2d,0x2d,0x20,0x44,0x54,0x3a,0x52,0x69,
- 0x63,0x68,0x20,0x2d,0x2d,0x3e,0x0a,0x3c,0x70,0x3e,0x33,0x64,0x74,
- 0x6f,0x33,0x64,0x20,0x69,0x73,0x20,0x61,0x20,0x63,0x6f,0x6d,0x6d,
- 0x61,0x6e,0x64,0x2d,0x6c,0x69,0x6e,0x65,0x20,0x74,0x6f,0x6f,0x6c,
- 0x20,0x61,0x62,0x6c,0x65,0x20,0x74,0x6f,0x20,0x63,0x6f,0x6e,0x76,
- 0x65,0x72,0x74,0x20,0x6f,0x62,0x6a,0x65,0x63,0x74,0x73,0x20,0x69,
- 0x6e,0x20,0x33,0x44,0x20,0x53,0x74,0x75,0x64,0x69,0x6f,0x2c,0x20,
- 0x49,0x6d,0x61,0x67,0x69,0x6e,0x65,0x0a,0x4f,0x62,0x6a,0x65,0x63,
- 0x74,0x2c,0x20,0x4c,0x69,0x67,0x68,0x74,0x57,0x61,0x76,0x65,0x20,
- 0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,0x20,0x41,0x75,0x74,0x6f,0x43,
- 0x61,0x64,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,0x20,0x50,0x6f,
- 0x76,0x72,0x61,0x79,0x20,0x42,0x69,0x6e,0x61,0x72,0x79,0x2c,0x20,
- 0x61,0x6e,0x64,0x20,0x57,0x61,0x76,0x65,0x46,0x72,0x6f,0x6e,0x74,
- 0x20,0x66,0x6f,0x72,0x6d,0x61,0x74,0x73,0x20,0x74,0x6f,0x0a,0x4d,
- 0x6f,0x72,0x61,0x79,0x2f,0x50,0x6f,0x76,0x72,0x61,0x79,0x2c,0x20,
- 0x4d,0x6f,0x72,0x61,0x79,0x2f,0x50,0x6f,0x6c,0x79,0x72,0x61,0x79,
- 0x2c,0x20,0x33,0x44,0x53,0x74,0x75,0x64,0x69,0x6f,0x2c,0x20,0x48,
- 0x69,0x67,0x68,0x4c,0x69,0x67,0x68,0x74,0x2c,0x20,0x52,0x65,0x61,
- 0x6c,0x33,0x44,0x20,0x4d,0x61,0x63,0x72,0x6f,0x2c,0x20,0x33,0x44,
- 0x20,0x53,0x74,0x75,0x64,0x69,0x6f,0x20,0x42,0x69,0x6e,0x61,0x72,
- 0x79,0x2c,0x0a,0x4d,0x6f,0x72,0x61,0x79,0x2f,0x50,0x6f,0x76,0x72,
- 0x61,0x79,0x20,0x28,0x57,0x69,0x72,0x65,0x29,0x2c,0x20,0x4d,0x6f,
- 0x72,0x61,0x79,0x2f,0x50,0x6f,0x76,0x72,0x61,0x79,0x20,0x28,0x42,
- 0x6c,0x6f,0x62,0x20,0x57,0x69,0x72,0x65,0x29,0x2c,0x20,0x49,0x6d,
- 0x61,0x67,0x69,0x6e,0x65,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,
- 0x20,0x52,0x65,0x6e,0x64,0x65,0x72,0x57,0x61,0x72,0x65,0x20,0x4f,
- 0x62,0x6a,0x65,0x63,0x74,0x2c,0x0a,0x56,0x52,0x4d,0x4c,0x20,0x4f,
- 0x62,0x6a,0x65,0x63,0x74,0x2c,0x20,0x44,0x58,0x46,0x20,0x4f,0x62,
- 0x6a,0x65,0x63,0x74,0x2c,0x20,0x4c,0x69,0x67,0x68,0x74,0x77,0x61,
- 0x76,0x65,0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,0x20,0x44,0x69,
- 0x72,0x65,0x63,0x74,0x20,0x58,0x20,0x28,0x4d,0x69,0x63,0x72,0x6f,
- 0x73,0x6f,0x66,0x74,0x29,0x2c,0x20,0x52,0x65,0x61,0x6c,0x33,0x44,
- 0x20,0x4f,0x62,0x6a,0x65,0x63,0x74,0x2c,0x0a,0x4f,0x70,0x65,0x6e,
- 0x47,0x4c,0x20,0x43,0x20,0x73,0x6f,0x75,0x72,0x63,0x65,0x2c,0x20,
- 0x6f,0x72,0x20,0x57,0x61,0x76,0x65,0x46,0x72,0x6f,0x6e,0x74,0x20,
- 0x66,0x6f,0x72,0x6d,0x61,0x74,0x2e,0x0a,0x3c,0x2f,0x70,0x3e,0x0a,
- 0x2d,0x44,0x65,0x73,0x3a,0x0a,0x23,0x23,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,
- 0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x2d,0x0a,0x3d,0x50,0x6b,
- 0x67,0x3a,0x20,0x39,0x31,0x35,0x72,0x65,0x73,0x6f,0x6c,0x75,0x74,
- 0x69,0x6f,0x6e,0x20,0x30,0x2e,0x35,0x2e,0x32,0x20,0x31,0x34,0x20,
- 0x69,0x35,0x38,0x36,0x0a,0x3d,0x53,0x75,0x6d,0x3a,0x20,0x54,0x68,
- 0x69,0x73,0x20,0x73,0x6f,0x66,0x74,0x77,0x61,0x72,0x65,0x20,0x63,
- 0x68,0x61,0x6e,0x67,0x65,0x73,0x20,0x74,0x68,0x65,0x20,0x72,0x65,
- 0x73,0x6f,0x6c,0x75,0x74,0x69,0x6f,0x6e,0x20,0x6f,0x66,0x20,0x61,
- 0x6e,0x20,0x61,0x76,0x61,0x69,0x6c,0x61,0x62,0x6c,0x65,0x20,0x76,
- 0x62,0x69,0x6f,0x73,0x20,0x6d,0x6f,0x64,0x65,0x2e,0x0a,0x2b,0x44,
- 0x65,0x73,0x3a,0x0a,0x3c,0x21,0x2d,0x2d,0x20,0x44,0x54,0x3a,0x52,
- 0x69,0x63,0x68,0x20,0x2d,0x2d,0x3e,0x0a,0x3c,0x70,0x3e,0x54,0x68,
- 0x69,0x73,0x20,0x73,0x6f,0x66,0x74,0x77,0x61,0x72,0x65,0x20,0x63,
- 0x68,0x61,0x6e,0x67,0x65,0x73,0x20,0x74,0x68,0x65,0x20,0x72,0x65,
- 0x73,0x6f,0x6c,0x75,0x74,0x69,0x6f,0x6e,0x20,0x6f,0x66,0x20,0x61,
- 0x6e,0x20,0x61,0x76,0x61,0x69,0x6c,0x61,0x62,0x6c,0x65,0x20,0x76,
- 0x62,0x69,0x6f,0x73,0x20,0x6d,0x6f,0x64,0x65,0x2e,0x0a,0x3c,0x2f,
- 0x70,0x3e,0x3c,0x70,0x3e,0x0a,0x49,0x74,0x20,0x70,0x61,0x74,0x63,
- 0x68,0x65,0x73,0x20,0x6f,0x6e,0x6c,0x79,0x20,0x74,0x68,0x65,0x20,
- 0x52,0x41,0x4d,0x20,0x76,0x65,0x72,0x73,0x69,0x6f,0x6e,0x20,0x6f,
- 0x66,0x20,0x74,0x68,0x65,0x20,0x76,0x69,0x64,0x65,0x6f,0x20,0x62,
- 0x69,0x6f,0x73,0x20,0x73,0x6f,0x20,0x74,0x68,0x65,0x20,0x6e,0x65,
- 0x77,0x20,0x72,0x65,0x73,0x6f,0x6c,0x75,0x74,0x69,0x6f,0x6e,0x0a,
- 0x69,0x73,0x20,0x6c,0x6f,0x6f,0x73,0x65,0x20,0x65,0x61,0x63,0x68,
- 0x20,0x74,0x69,0x6d,0x65,0x20,0x79,0x6f,0x75,0x20,0x72,0x65,0x62,
- 0x6f,0x6f,0x74,0x2e,0x20,0x49,0x66,0x20,0x79,0x6f,0x75,0x20,0x77,
- 0x61,0x6e,0x74,0x20,0x74,0x6f,0x20,0x73,0x65,0x74,0x20,0x74,0x68,
- 0x65,0x20,0x72,0x65,0x73,0x6f,0x6c,0x75,0x74,0x69,0x6f,0x6e,0x20,
- 0x65,0x61,0x63,0x68,0x0a,0x74,0x69,0x6d,0x65,0x20,0x79,0x6f,0x75,
- 0x20,0x72,0x65,0x62,0x6f,0x6f,0x74,0x20,0x61,0x6e,0x64,0x20,0x62,
- 0x65,0x66,0x6f,0x72,0x65,0x20,0x74,0x6f,0x20,0x6c,0x61,0x75,0x6e,
- 0x63,0x68,0x20,0x58,0x2c,0x20,0x75,0x73,0x65,0x20,0x79,0x6f,0x75,
- 0x72,0x20,0x72,0x63,0x2e,0x6c,0x6f,0x63,0x61,0x6c,0x2c,0x20,0x6c,
- 0x6f,0x63,0x61,0x6c,0x2e,0x73,0x74,0x61,0x72,0x74,0x20,0x2e,0x2e,
- 0x2e,0x0a,0x66,0x69,0x6c,0x65,0x20,0x6f,0x66,0x20,0x79,0x6f,0x75,
- 0x72,0x20,0x4c,0x69,0x6e,0x75,0x78,0x20,0x76,0x65,0x72,0x73,0x69,
- 0x6f,0x6e,0x2e,0x0a,0x3c,0x2f,0x70,0x3e,0x3c,0x70,0x3e,0x0a,0x39,
- 0x31,0x35,0x72,0x65,0x73,0x6f,0x6c,0x75,0x74,0x69,0x6f,0x6e,0x20,
- 0x73,0x75,0x70,0x70,0x6f,0x72,0x74,0x73,0x20,0x74,0x68,0x65,0x20,
- 0x38,0x34,0x35,0x47,0x2c,0x20,0x38,0x35,0x35,0x47,0x4d,0x2c,0x20,
- 0x38,0x36,0x35,0x47,0x2c,0x20,0x39,0x31,0x35,0x47,0x2c,0x20,0x39,
- 0x31,0x35,0x47,0x4d,0x2c,0x20,0x39,0x34,0x35,0x47,0x2c,0x20,0x61,
- 0x6e,0x64,0x20,0x39,0x34,0x35,0x47,0x4d,0x20,0x63,0x68,0x69,0x70,
- 0x73,0x65,0x74,0x73,0x2e,0x0a,0x3c,0x2f,0x70,0x3e,0x0a,0x2d,0x44,
- 0x65,0x73,0x3a,0x0a,0x00,
-};
-
-size_t _descfile_size=2240;
-size_t *descfile_size=&_descfile_size;
-
-void lazzy_test()
-{
- // prepare a file
- filesystem::TmpFile file;
- ofstream str(file.path().asString().c_str(),ofstream::out);
-
- if (!str.good())
- ZYPP_THROW(Exception("cant open file"));
-
- str << descfile;
- str.flush();
- str.close();
-
- zypp::Lazy<std::string> lazzy_text(lazyTextFromFile( file.path(), 1415, 16));
-
- BOOST_CHECK_EQUAL( lazzy_text.value(), "3D Studio Binary" );
-
- zypp::Lazy<std::string> nofile_text(lazyTextFromFile( Pathname("notexists"), 0, 10));
- BOOST_CHECK_THROW( nofile_text.value(), Exception );
-}
-
-test_suite*
-init_unit_test_suite( int argc, char* argv[] )
-{
- test_suite* test= BOOST_TEST_SUITE( "LazyTextTest" );
- test->add( BOOST_TEST_CASE( &lazzy_test ), 0 /* expected zero error */ );
- return test;
-}
-