Lines Matching refs:CHK

255 	CHK(node.GetAttrInfo(name, &info) == B_OK);
256 CHK(info.type == type);
262 CHK(false);
274 CHK(resources.SetTo(&file) == B_OK);
276 CHK(resources.GetResourceInfo(type, name, &idFound, &size) == true);
277 CHK(idFound == id);
279 CHK(resourceData != NULL);
292 CHK(node.GetAttrInfo(name, &info) == B_OK);
293 CHK(info.type == type);
294 CHK(info.size == dataSize);
297 CHK(node.ReadAttr(name, type, 0, buffer, dataSize) == dataSize);
298 CHK(memcmp(buffer, data, dataSize) == 0);
308 CHK(resources.SetTo(&file) == B_OK);
311 CHK(resources.GetResourceInfo(type, name, &idFound, &size) == true);
312 CHK(idFound == id);
313 CHK(size == dataSize);
315 CHK(resourceData != NULL);
316 CHK(size == dataSize);
317 CHK(memcmp(resourceData, data, dataSize) == 0);
326 CHK(node.GetAttrInfo(name, &info) == B_ENTRY_NOT_FOUND);
335 CHK(resources.SetTo(&file) == B_OK);
347 CHK(!found);
552 CHK(storedTypes.Unflatten(buffer) == B_OK);
554 CHK(storedValue == value);
565 CHK(storedTypes.Unflatten(buffer) == B_OK);
567 CHK(storedValue == value);
861 CHK(false);
887 CHK(false);
932 CHK(false);
962 CHK(false);
984 CHK(false);
1005 CHK(false);
1027 CHK(appFileInfo.InitCheck() == B_NO_INIT);
1028 CHK(appFileInfo.IsUsingAttributes() == hasInitialLocation);
1029 CHK(appFileInfo.IsUsingResources() == hasInitialLocation);
1037 CHK(appFileInfo.InitCheck() == B_BAD_VALUE);
1038 CHK(appFileInfo.IsUsingAttributes() == hasInitialLocation);
1039 CHK(appFileInfo.IsUsingResources() == hasInitialLocation);
1046 CHK(appFileInfo.InitCheck() == B_BAD_VALUE);
1047 CHK(appFileInfo.IsUsingAttributes() == hasInitialLocation);
1048 CHK(appFileInfo.IsUsingResources() == hasInitialLocation);
1055 CHK(appFileInfo.InitCheck() == B_OK);
1056 CHK(appFileInfo.IsUsingAttributes() == true);
1057 CHK(appFileInfo.IsUsingResources() == true);
1075 CHK(appFileInfo.SetTo(NULL) == B_BAD_VALUE);
1076 CHK(appFileInfo.InitCheck() == B_BAD_VALUE);
1077 CHK(appFileInfo.IsUsingAttributes() == hasInitialLocation);
1078 CHK(appFileInfo.IsUsingResources() == hasInitialLocation);
1085 CHK(appFileInfo.SetTo(&file) == B_BAD_VALUE);
1086 CHK(appFileInfo.InitCheck() == B_BAD_VALUE);
1087 CHK(appFileInfo.IsUsingAttributes() == hasInitialLocation);
1088 CHK(appFileInfo.IsUsingResources() == hasInitialLocation);
1096 CHK(appFileInfo.SetTo(&file) == B_OK);
1097 CHK(appFileInfo.InitCheck() == B_OK);
1098 CHK(appFileInfo.IsUsingAttributes() == true);
1099 CHK(appFileInfo.IsUsingResources() == true);
1101 CHK(file.GetSize(&size) == B_OK);
1102 CHK(size == 0);
1107 CHK(appFileInfo.SetTo(NULL) == B_BAD_VALUE);
1108 CHK(appFileInfo.InitCheck() == B_BAD_VALUE);
1109 CHK(appFileInfo.IsUsingAttributes() == true);
1110 CHK(appFileInfo.IsUsingResources() == true);
1111 CHK(file.GetSize(&size) == B_OK);
1112 CHK(size == 0);
1118 CHK(appFileInfo.SetTo(&file2) == B_OK);
1119 CHK(appFileInfo.InitCheck() == B_OK);
1120 CHK(appFileInfo.IsUsingAttributes() == true);
1121 CHK(appFileInfo.IsUsingResources() == true);
1135 CHK(appFileInfo.SetTo(&file) == B_OK);
1136 CHK(equals(appFileInfo.GetType(NULL), B_BAD_ADDRESS, B_BAD_VALUE));
1143 CHK(appFileInfo.GetType(type) == B_NO_INIT);
1150 CHK(appFileInfo.SetTo(&file) == B_OK);
1152 CHK(appFileInfo.GetType(type) == B_ENTRY_NOT_FOUND);
1159 CHK(appFileInfo.SetTo(&file) == B_OK);
1161 CHK(appFileInfo.SetType(testType1) == B_OK);
1164 CHK(appFileInfo.GetType(type) == B_OK);
1165 CHK(strcmp(testType1, type) == 0);
1170 CHK(appFileInfo.SetType(testType2) == B_OK);
1172 CHK(appFileInfo.GetType(type) == B_OK);
1173 CHK(strcmp(testType2, type) == 0);
1185 CHK(appFileInfo.SetTo(&file) == B_OK);
1186 CHK(appFileInfo.SetType(NULL) == B_OK);
1189 CHK(appFileInfo.GetType(type) == B_ENTRY_NOT_FOUND);
1198 CHK(appFileInfo.SetType(testType1) == B_NO_INIT);
1205 CHK(appFileInfo.SetTo(&file) == B_OK);
1206 CHK(appFileInfo.SetType(invalidTestType) == B_OK);
1209 CHK(appFileInfo.GetType(type) == B_OK);
1210 CHK(strcmp(invalidTestType, type) == 0);
1220 CHK(appFileInfo.SetTo(&file) == B_OK);
1222 CHK(appFileInfo.SetType(NULL) == B_OK);
1224 CHK(appFileInfo.SetType(tooLongTestType) == B_BAD_VALUE);
1241 CHK(appFileInfo.SetTo(&file) == B_OK);
1242 CHK(equals(appFileInfo.GetSignature(NULL), B_BAD_ADDRESS, B_BAD_VALUE));
1249 CHK(appFileInfo.GetSignature(signature) == B_NO_INIT);
1256 CHK(appFileInfo.SetTo(&file) == B_OK);
1258 CHK(appFileInfo.GetSignature(signature) == B_ENTRY_NOT_FOUND);
1265 CHK(appFileInfo.SetTo(&file) == B_OK);
1267 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1268 CHK(BMimeType(testAppSignature1).IsInstalled() == false);
1271 CHK(appFileInfo.GetSignature(signature) == B_OK);
1272 CHK(strcmp(testAppSignature1, signature) == 0);
1277 CHK(appFileInfo.SetSignature(testAppSignature2) == B_OK);
1278 CHK(BMimeType(testAppSignature2).IsInstalled() == false);
1280 CHK(appFileInfo.GetSignature(signature) == B_OK);
1281 CHK(strcmp(testAppSignature2, signature) == 0);
1293 CHK(appFileInfo.SetTo(&file) == B_OK);
1294 CHK(appFileInfo.SetSignature(NULL) == B_OK);
1297 CHK(appFileInfo.GetSignature(signature) == B_ENTRY_NOT_FOUND);
1306 CHK(appFileInfo.SetSignature(testAppSignature1) == B_NO_INIT);
1313 CHK(appFileInfo.SetTo(&file) == B_OK);
1314 CHK(appFileInfo.SetSignature(invalidTestType) == B_OK);
1317 CHK(appFileInfo.GetSignature(signature) == B_OK);
1318 CHK(strcmp(invalidTestType, signature) == 0);
1328 CHK(appFileInfo.SetTo(&file) == B_OK);
1330 CHK(appFileInfo.SetSignature(NULL) == B_OK);
1332 CHK(appFileInfo.SetSignature(tooLongTestType) == B_BAD_VALUE);
1349 CHK(appFileInfo.SetTo(&file) == B_OK);
1350 CHK(equals(appFileInfo.GetAppFlags(NULL), B_BAD_ADDRESS, B_BAD_VALUE));
1357 CHK(appFileInfo.GetAppFlags(&flags) == B_NO_INIT);
1364 CHK(appFileInfo.SetTo(&file) == B_OK);
1366 CHK(appFileInfo.GetAppFlags(&flags) == B_ENTRY_NOT_FOUND);
1375 CHK(appFileInfo.SetTo(&file) == B_OK);
1377 CHK(appFileInfo.SetAppFlags(testFlags1) == B_OK);
1380 CHK(appFileInfo.GetAppFlags(&flags) == B_OK);
1381 CHK(flags == testFlags1);
1386 CHK(appFileInfo.SetAppFlags(testFlags2) == B_OK);
1388 CHK(appFileInfo.GetAppFlags(&flags) == B_OK);
1389 CHK(flags == testFlags2);
1400 CHK(appFileInfo.SetAppFlags(B_SINGLE_LAUNCH) == B_NO_INIT);
1410 // CHK(BMimeType(type).GetSupportingApps(&apps) == B_OK);
1428 CHK(testTypes1.AddString("types", testType1) == B_OK);
1429 CHK(testTypes1.AddString("types", testType2) == B_OK);
1431 CHK(testTypes2.AddString("types", testType3) == B_OK);
1432 CHK(testTypes2.AddString("types", testType4) == B_OK);
1441 CHK(appFileInfo.SetTo(&file) == B_OK);
1442 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1443 CHK(BMimeType(testAppSignature1).Install() == B_OK);
1452 CHK(appFileInfo.GetSupportedTypes(&types) == B_NO_INIT);
1459 CHK(appFileInfo.SetTo(&file) == B_OK);
1461 CHK(appFileInfo.GetSupportedTypes(&types) == B_ENTRY_NOT_FOUND);
1468 CHK(appFileInfo.SetTo(&file) == B_OK);
1470 CHK(BMimeType(testType1).IsInstalled() == false);
1471 CHK(BMimeType(testType2).IsInstalled() == false);
1472 CHK(appFileInfo.SetSupportedTypes(&testTypes1) == B_OK);
1475 CHK(appFileInfo.GetSupportedTypes(&types) == B_OK);
1476 CHK(SupportedTypesValue(types) == SupportedTypesValue(testTypes1));
1477 CHK(appFileInfo.IsSupportedType(testType1) == true);
1478 CHK(appFileInfo.IsSupportedType(testType2) == true);
1479 CHK(appFileInfo.Supports(&mimeTestType1) == true);
1480 CHK(appFileInfo.Supports(&mimeTestType2) == true);
1484 CHK(BMimeType(testType1).IsInstalled() == true);
1485 CHK(BMimeType(testType2).IsInstalled() == true);
1487 CHK(BMimeType(testType3).IsInstalled() == false);
1488 CHK(BMimeType(testType4).IsInstalled() == false);
1489 CHK(appFileInfo.SetSupportedTypes(&testTypes2) == B_OK);
1492 CHK(appFileInfo.GetSupportedTypes(&types2) == B_OK);
1493 CHK(SupportedTypesValue(types2) == SupportedTypesValue(testTypes2));
1494 CHK(appFileInfo.IsSupportedType(testType1) == false);
1495 CHK(appFileInfo.IsSupportedType(testType2) == false);
1496 CHK(appFileInfo.IsSupportedType(testType3) == true);
1497 CHK(appFileInfo.IsSupportedType(testType4) == true);
1498 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1499 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1500 CHK(appFileInfo.Supports(&mimeTestType3) == true);
1501 CHK(appFileInfo.Supports(&mimeTestType4) == true);
1505 CHK(BMimeType(testType3).IsInstalled() == true);
1506 CHK(BMimeType(testType4).IsInstalled() == true);
1513 CHK(appFileInfo.SetTo(&file) == B_OK);
1515 CHK(types2.AddString("types", testType1) == B_OK);
1516 CHK(types2.AddString("dummy", "Hello") == B_OK);
1517 CHK(appFileInfo.GetSupportedTypes(&types2) == B_OK);
1518 CHK(SupportedTypesValue(types2) == SupportedTypesValue(testTypes2));
1520 CHK(types2.FindString("dummy", &dummy) != B_OK);
1529 CHK(appFileInfo.SetTo(&file) == B_OK);
1530 CHK(appFileInfo.GetSupportedTypes(NULL) == B_BAD_VALUE);
1541 CHK(appFileInfo.SetSupportedTypes(&types) == B_NO_INIT);
1548 CHK(appFileInfo.SetTo(&file) == B_OK);
1550 CHK(appFileInfo.SetSupportedTypes(NULL) == B_OK);
1553 CHK(appFileInfo.GetSupportedTypes(&types) == B_ENTRY_NOT_FOUND);
1554 CHK(appFileInfo.IsSupportedType(testType1) == false);
1555 CHK(appFileInfo.IsSupportedType(testType2) == false);
1556 CHK(appFileInfo.IsSupportedType(testType3) == false);
1557 CHK(appFileInfo.IsSupportedType(testType4) == false);
1558 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1559 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1560 CHK(appFileInfo.Supports(&mimeTestType3) == false);
1561 CHK(appFileInfo.Supports(&mimeTestType4) == false);
1568 CHK(appFileInfo.SetSupportedTypes(&testTypes1) == B_OK);
1569 CHK(appFileInfo.SetSupportedTypes(NULL, true) == B_OK);
1571 CHK(appFileInfo.GetSupportedTypes(&types) == B_ENTRY_NOT_FOUND);
1572 CHK(appFileInfo.IsSupportedType(testType1) == false);
1573 CHK(appFileInfo.IsSupportedType(testType2) == false);
1574 CHK(appFileInfo.IsSupportedType(testType3) == false);
1575 CHK(appFileInfo.IsSupportedType(testType4) == false);
1576 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1577 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1578 CHK(appFileInfo.Supports(&mimeTestType3) == false);
1579 CHK(appFileInfo.Supports(&mimeTestType4) == false);
1589 CHK(BMimeType(testType1).Delete() == B_OK);
1590 CHK(BMimeType(testType2).Delete() == B_OK);
1591 CHK(BMimeType(testType3).Delete() == B_OK);
1592 CHK(BMimeType(testType4).Delete() == B_OK);
1593 CHK(BMimeType(testAppSignature1).Delete() == B_OK);
1594 CHK(BMimeType(testAppSignature1).Install() == B_OK);
1595 CHK(BEntry(testFile1).Remove() == B_OK);
1599 CHK(appFileInfo.SetTo(&file) == B_OK);
1600 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1602 CHK(appFileInfo.SetSupportedTypes(&testTypes1) == B_OK);
1604 CHK(IsSupportingApp(testType1, testAppSignature1) == true);
1605 CHK(IsSupportingApp(testType2, testAppSignature1) == true);
1607 CHK(appFileInfo.SetSupportedTypes(&testTypes2) == B_OK);
1609 CHK(IsSupportingApp(testType1, testAppSignature1) == true);
1610 CHK(IsSupportingApp(testType2, testAppSignature1) == true);
1611 CHK(IsSupportingApp(testType3, testAppSignature1) == true);
1612 CHK(IsSupportingApp(testType4, testAppSignature1) == true);
1618 CHK(BMimeType(testType1).Delete() == B_OK);
1619 CHK(BMimeType(testType2).Delete() == B_OK);
1620 CHK(BMimeType(testType3).Delete() == B_OK);
1621 CHK(BMimeType(testType4).Delete() == B_OK);
1622 CHK(BMimeType(testAppSignature1).Delete() == B_OK);
1623 CHK(BMimeType(testAppSignature1).Install() == B_OK);
1624 CHK(BEntry(testFile1).Remove() == B_OK);
1628 CHK(appFileInfo.SetTo(&file) == B_OK);
1629 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1631 CHK(appFileInfo.SetSupportedTypes(&testTypes1, false) == B_OK);
1633 CHK(IsSupportingApp(testType1, testAppSignature1) == true);
1634 CHK(IsSupportingApp(testType2, testAppSignature1) == true);
1636 CHK(appFileInfo.SetSupportedTypes(&testTypes2, false) == B_OK);
1638 CHK(IsSupportingApp(testType1, testAppSignature1) == true);
1639 CHK(IsSupportingApp(testType2, testAppSignature1) == true);
1640 CHK(IsSupportingApp(testType3, testAppSignature1) == true);
1641 CHK(IsSupportingApp(testType4, testAppSignature1) == true);
1647 CHK(BMimeType(testType1).Delete() == B_OK);
1648 CHK(BMimeType(testType2).Delete() == B_OK);
1649 CHK(BMimeType(testType3).Delete() == B_OK);
1650 CHK(BMimeType(testType4).Delete() == B_OK);
1651 CHK(BMimeType(testAppSignature1).Delete() == B_OK);
1652 CHK(BMimeType(testAppSignature1).Install() == B_OK);
1653 CHK(BEntry(testFile1).Remove() == B_OK);
1657 CHK(appFileInfo.SetTo(&file) == B_OK);
1658 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1660 CHK(appFileInfo.SetSupportedTypes(&testTypes1, true) == B_OK);
1662 CHK(IsSupportingApp(testType1, testAppSignature1) == true);
1663 CHK(IsSupportingApp(testType2, testAppSignature1) == true);
1665 CHK(appFileInfo.SetSupportedTypes(&testTypes2, true) == B_OK);
1667 CHK(IsSupportingApp(testType1, testAppSignature1) == false);
1668 CHK(IsSupportingApp(testType2, testAppSignature1) == false);
1669 CHK(IsSupportingApp(testType3, testAppSignature1) == true);
1670 CHK(IsSupportingApp(testType4, testAppSignature1) == true);
1680 CHK(appFileInfo.SetTo(&file) == B_OK);
1683 CHK(invalidTestTypes.AddString("types", invalidTestType) == B_OK);
1684 CHK(appFileInfo.SetSupportedTypes(NULL, true) == B_OK);
1685 CHK(appFileInfo.SetSupportedTypes(&invalidTestTypes, false)
1689 CHK(appFileInfo.GetSupportedTypes(&types) == B_ENTRY_NOT_FOUND);
1690 CHK(appFileInfo.IsSupportedType(invalidTestType) == false);
1704 CHK(appFileInfo.SetTo(&file) == B_OK);
1705 CHK(appFileInfo.IsSupportedType(NULL) == false);
1708 CHK(appFileInfo.Supports(NULL) == false);
1716 CHK(appFileInfo.SetTo(&file) == B_OK);
1718 CHK(appFileInfo.IsSupportedType(gifType.Type()) == false);
1719 CHK(appFileInfo.Supports(&gifType) == false);
1721 CHK(types.AddString("types", "application/octet-stream") == B_OK);
1722 CHK(appFileInfo.SetSupportedTypes(&types) == B_OK);
1723 CHK(appFileInfo.IsSupportedType(gifType.Type()) == true);
1724 CHK(appFileInfo.Supports(&gifType) == false);
1726 CHK(appFileInfo.SetSupportedTypes(&noTypes, true) == B_OK);
1734 CHK(BMimeType(testType1).Delete() == B_OK);
1735 CHK(BMimeType(testType2).Delete() == B_OK);
1736 CHK(BMimeType(testType3).Delete() == B_OK);
1737 CHK(BMimeType(testType4).Delete() == B_OK);
1738 CHK(BMimeType(testAppSignature1).Delete() == B_OK);
1739 CHK(BEntry(testFile1).Remove() == B_OK);
1743 CHK(appFileInfo.SetTo(&file) == B_OK);
1744 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1746 CHK(BMimeType(testType1).IsInstalled() == false);
1747 CHK(BMimeType(testType2).IsInstalled() == false);
1748 CHK(appFileInfo.SetSupportedTypes(&testTypes1, true) == B_OK);
1751 CHK(appFileInfo.GetSupportedTypes(&types) == B_OK);
1752 CHK(SupportedTypesValue(types) == SupportedTypesValue(testTypes1));
1753 CHK(appFileInfo.IsSupportedType(testType1) == true);
1754 CHK(appFileInfo.IsSupportedType(testType2) == true);
1755 CHK(appFileInfo.Supports(&mimeTestType1) == true);
1756 CHK(appFileInfo.Supports(&mimeTestType2) == true);
1760 CHK(BMimeType(testType1).IsInstalled() == false);
1761 CHK(BMimeType(testType2).IsInstalled() == false);
1763 CHK(BMimeType(testType3).IsInstalled() == false);
1764 CHK(BMimeType(testType4).IsInstalled() == false);
1765 CHK(appFileInfo.SetSupportedTypes(&testTypes2, true) == B_OK);
1767 CHK(appFileInfo.GetSupportedTypes(&types) == B_OK);
1768 CHK(SupportedTypesValue(types) == SupportedTypesValue(testTypes2));
1769 CHK(appFileInfo.IsSupportedType(testType1) == false);
1770 CHK(appFileInfo.IsSupportedType(testType2) == false);
1771 CHK(appFileInfo.IsSupportedType(testType3) == true);
1772 CHK(appFileInfo.IsSupportedType(testType4) == true);
1773 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1774 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1775 CHK(appFileInfo.Supports(&mimeTestType3) == true);
1776 CHK(appFileInfo.Supports(&mimeTestType4) == true);
1780 CHK(BMimeType(testType1).IsInstalled() == false);
1781 CHK(BMimeType(testType2).IsInstalled() == false);
1782 CHK(BMimeType(testType3).IsInstalled() == false);
1786 CHK(BMimeType(testType4).IsInstalled() == false);
1798 CHK(BEntry(testFile1).Remove() == B_OK);
1802 CHK(appFileInfo.SetTo(&file) == B_OK);
1803 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1805 CHK(BMimeType(testType1).IsInstalled() == false);
1806 CHK(BMimeType(testType2).IsInstalled() == false);
1810 CHK(appFileInfo.SetSupportedTypes(&testTypes1) == B_ENTRY_NOT_FOUND);
1812 CHK(appFileInfo.SetSupportedTypes(&testTypes1) == B_OK);
1816 CHK(appFileInfo.GetSupportedTypes(&types) == B_OK);
1817 CHK(SupportedTypesValue(types) == SupportedTypesValue(testTypes1));
1818 CHK(appFileInfo.IsSupportedType(testType1) == true);
1819 CHK(appFileInfo.IsSupportedType(testType2) == true);
1820 CHK(appFileInfo.Supports(&mimeTestType1) == true);
1821 CHK(appFileInfo.Supports(&mimeTestType2) == true);
1825 CHK(BMimeType(testType1).IsInstalled() == false);
1826 CHK(BMimeType(testType2).IsInstalled() == false);
1828 CHK(BMimeType(testType3).IsInstalled() == false);
1829 CHK(BMimeType(testType4).IsInstalled() == false);
1833 CHK(appFileInfo.SetSupportedTypes(&testTypes2) == B_ENTRY_NOT_FOUND);
1835 CHK(appFileInfo.SetSupportedTypes(&testTypes2) == B_OK);
1838 CHK(appFileInfo.GetSupportedTypes(&types) == B_OK);
1839 CHK(SupportedTypesValue(types) == SupportedTypesValue(testTypes2));
1840 CHK(appFileInfo.IsSupportedType(testType1) == false);
1841 CHK(appFileInfo.IsSupportedType(testType2) == false);
1842 CHK(appFileInfo.IsSupportedType(testType3) == true);
1843 CHK(appFileInfo.IsSupportedType(testType4) == true);
1844 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1845 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1846 CHK(appFileInfo.Supports(&mimeTestType3) == true);
1847 CHK(appFileInfo.Supports(&mimeTestType4) == true);
1851 CHK(BMimeType(testType1).IsInstalled() == false);
1852 CHK(BMimeType(testType2).IsInstalled() == false);
1853 CHK(BMimeType(testType3).IsInstalled() == false);
1857 CHK(BMimeType(testType4).IsInstalled() == false);
1869 CHK(BEntry(testFile1).Remove() == B_OK);
1873 CHK(appFileInfo.SetTo(&file) == B_OK);
1875 CHK(BMimeType(testType1).IsInstalled() == false);
1876 CHK(BMimeType(testType2).IsInstalled() == false);
1877 CHK(appFileInfo.SetSupportedTypes(&testTypes1, true)
1881 CHK(appFileInfo.GetSupportedTypes(&types) == B_ENTRY_NOT_FOUND);
1882 CHK(appFileInfo.IsSupportedType(testType1) == false);
1883 CHK(appFileInfo.IsSupportedType(testType2) == false);
1884 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1885 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1889 CHK(BMimeType(testType1).IsInstalled() == false);
1890 CHK(BMimeType(testType2).IsInstalled() == false);
1892 CHK(BMimeType(testType1).IsInstalled() == false);
1893 CHK(BMimeType(testType2).IsInstalled() == false);
1894 CHK(appFileInfo.SetSupportedTypes(&testTypes1) == B_ENTRY_NOT_FOUND);
1896 CHK(appFileInfo.GetSupportedTypes(&types) == B_ENTRY_NOT_FOUND);
1897 CHK(appFileInfo.IsSupportedType(testType1) == false);
1898 CHK(appFileInfo.IsSupportedType(testType2) == false);
1899 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1900 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1904 CHK(BMimeType(testType1).IsInstalled() == false);
1905 CHK(BMimeType(testType2).IsInstalled() == false);
1916 CHK(BMimeType(testAppSignature1).Install() == B_OK);
1917 CHK(BEntry(testFile1).Remove() == B_OK);
1921 CHK(appFileInfo.SetTo(&file) == B_OK);
1922 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1924 CHK(appFileInfo.SetSupportedTypes(&testTypes1) == B_OK);
1927 CHK(appFileInfo.GetSupportedTypes(&types) == B_OK);
1928 CHK(SupportedTypesValue(types) == SupportedTypesValue(testTypes1));
1929 CHK(appFileInfo.IsSupportedType(testType1) == true);
1930 CHK(appFileInfo.IsSupportedType(testType2) == true);
1931 CHK(appFileInfo.Supports(&mimeTestType1) == true);
1932 CHK(appFileInfo.Supports(&mimeTestType2) == true);
1936 CHK(IsSupportingApp(testType1, testAppSignature1) == true);
1937 CHK(IsSupportingApp(testType2, testAppSignature1) == true);
1941 CHK(BEntry(testFile1).Remove() == B_OK);
1943 CHK(file.SetTo(testFile1, B_READ_WRITE | B_CREATE_FILE) == B_OK);
1944 CHK(appFileInfo.SetTo(&file) == B_OK);
1945 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
1948 CHK(appFileInfo.GetSupportedTypes(&types2) == B_ENTRY_NOT_FOUND);
1949 CHK(appFileInfo.IsSupportedType(testType1) == false);
1950 CHK(appFileInfo.IsSupportedType(testType2) == false);
1951 CHK(appFileInfo.Supports(&mimeTestType1) == false);
1952 CHK(appFileInfo.Supports(&mimeTestType2) == false);
1956 CHK(IsSupportingApp(testType1, testAppSignature1) == true);
1957 CHK(IsSupportingApp(testType2, testAppSignature1) == true);
1971 CHK(appFileInfo.SetTo(&file) == B_OK);
1972 CHK(appFileInfo.GetIcon(NULL, B_MINI_ICON) == B_BAD_VALUE);
1973 CHK(appFileInfo.GetIcon(NULL, B_LARGE_ICON) == B_BAD_VALUE);
1980 CHK(appFileInfo.GetIcon(&icon, B_MINI_ICON) == B_NO_INIT);
1982 CHK(appFileInfo.GetIcon(&icon2, B_LARGE_ICON) == B_NO_INIT);
1989 CHK(appFileInfo.SetTo(&file) == B_OK);
1991 CHK(appFileInfo.GetIcon(&icon, B_MINI_ICON) == B_BAD_VALUE);
1993 CHK(appFileInfo.GetIcon(&icon2, B_LARGE_ICON) == B_BAD_VALUE);
2000 CHK(appFileInfo.SetTo(&file) == B_OK);
2002 CHK(appFileInfo.GetIcon(&icon, B_MINI_ICON) == B_ENTRY_NOT_FOUND);
2009 CHK(appFileInfo.SetTo(&file) == B_OK);
2012 CHK(appFileInfo.SetIcon(fIconM1, B_MINI_ICON) == B_OK);
2015 CHK(appFileInfo.GetIcon(&icon, B_MINI_ICON) == B_OK);
2016 CHK(icon_equal(fIconM1, &icon));
2021 CHK(appFileInfo.SetIcon(fIconM2, B_MINI_ICON) == B_OK);
2024 CHK(appFileInfo.GetIcon(&icon2, B_MINI_ICON) == B_OK);
2025 CHK(icon_equal(fIconM2, &icon2));
2031 CHK(appFileInfo.SetIcon(fIconL1, B_LARGE_ICON) == B_OK);
2034 CHK(appFileInfo.GetIcon(&icon3, B_LARGE_ICON) == B_OK);
2035 CHK(icon_equal(fIconL1, &icon3));
2040 CHK(appFileInfo.SetIcon(fIconL2, B_LARGE_ICON) == B_OK);
2043 CHK(appFileInfo.GetIcon(&icon4, B_LARGE_ICON) == B_OK);
2044 CHK(icon_equal(fIconL2, &icon4));
2054 CHK(appFileInfo.SetTo(&file) == B_OK);
2057 CHK(appFileInfo.GetIcon(&icon, B_MINI_ICON) == B_OK);
2061 CHK(icon_equal(&icon, &icon2));
2066 CHK(appFileInfo.GetIcon(&icon3, B_LARGE_ICON) == B_OK);
2070 CHK(icon_equal(&icon3, &icon4));
2080 CHK(appFileInfo.SetTo(&file) == B_OK);
2083 CHK(appFileInfo.SetIcon(NULL, B_MINI_ICON) == B_OK);
2086 CHK(appFileInfo.GetIcon(&icon, B_MINI_ICON) == B_ENTRY_NOT_FOUND);
2092 CHK(appFileInfo.SetIcon(NULL, B_LARGE_ICON) == B_OK);
2095 CHK(appFileInfo.GetIcon(&icon2, B_LARGE_ICON) == B_ENTRY_NOT_FOUND);
2105 CHK(appFileInfo.SetIcon(&icon, B_MINI_ICON) == B_NO_INIT);
2107 CHK(appFileInfo.SetIcon(&icon2, B_LARGE_ICON) == B_NO_INIT);
2114 CHK(appFileInfo.SetTo(&file) == B_OK);
2116 CHK(appFileInfo.SetIcon(&icon, B_MINI_ICON) == B_BAD_VALUE);
2118 CHK(appFileInfo.SetIcon(&icon2, B_LARGE_ICON) == B_BAD_VALUE);
2126 CHK(appFileInfo.SetTo(&file) == B_OK);
2129 CHK(mimeType.IsInstalled() == false);
2130 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
2131 CHK(appFileInfo.SetIcon(fIconM1, B_MINI_ICON) == B_OK);
2132 CHK(appFileInfo.SetIcon(fIconL1, B_LARGE_ICON) == B_OK);
2133 CHK(mimeType.IsInstalled() == true);
2136 CHK(mimeType.GetIcon(&icon, B_MINI_ICON) == B_OK);
2137 CHK(icon_equal(fIconM1, &icon));
2140 CHK(mimeType.GetIcon(&icon2, B_LARGE_ICON) == B_OK);
2141 CHK(icon_equal(fIconL1, &icon2));
2143 CHK(appFileInfo.SetIcon(fIconM2, B_MINI_ICON) == B_OK);
2144 CHK(appFileInfo.SetIcon(fIconL2, B_LARGE_ICON) == B_OK);
2147 CHK(mimeType.GetIcon(&icon3, B_MINI_ICON) == B_OK);
2148 CHK(icon_equal(fIconM2, &icon3));
2151 CHK(mimeType.GetIcon(&icon4, B_LARGE_ICON) == B_OK);
2152 CHK(icon_equal(fIconL2, &icon4));
2174 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND)
2177 CHK(appFileInfo.GetVersionInfo(&info2, B_SYSTEM_VERSION_KIND)
2185 CHK(appFileInfo.SetTo(&file) == B_OK);
2187 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND)
2190 CHK(appFileInfo.GetVersionInfo(&info2, B_SYSTEM_VERSION_KIND)
2198 CHK(appFileInfo.SetTo(&file) == B_OK);
2200 CHK(appFileInfo.SetVersionInfo(&testInfo1, B_APP_VERSION_KIND)
2204 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND) == B_OK);
2205 CHK(info == testInfo1);
2206 CHK(appFileInfo.GetVersionInfo(&info, B_SYSTEM_VERSION_KIND) == B_OK);
2208 CHK(appFileInfo.SetVersionInfo(&testInfo2, B_SYSTEM_VERSION_KIND)
2211 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND) == B_OK);
2212 CHK(info == testInfo1);
2213 CHK(appFileInfo.GetVersionInfo(&info, B_SYSTEM_VERSION_KIND) == B_OK);
2214 CHK(info == testInfo2);
2220 CHK(appFileInfo.SetVersionInfo(&testInfo3, B_APP_VERSION_KIND)
2223 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND) == B_OK);
2224 CHK(info == testInfo3);
2225 CHK(appFileInfo.GetVersionInfo(&info, B_SYSTEM_VERSION_KIND) == B_OK);
2226 CHK(info == testInfo2);
2232 CHK(appFileInfo.SetVersionInfo(&testInfo4, B_SYSTEM_VERSION_KIND)
2235 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND) == B_OK);
2236 CHK(info == testInfo3);
2237 CHK(appFileInfo.GetVersionInfo(&info, B_SYSTEM_VERSION_KIND) == B_OK);
2238 CHK(info == testInfo4);
2251 CHK(appFileInfo.SetTo(&file) == B_OK);
2252 CHK(equals(appFileInfo.GetVersionInfo(NULL, B_APP_VERSION_KIND),
2254 CHK(equals(appFileInfo.GetVersionInfo(NULL, B_SYSTEM_VERSION_KIND),
2267 CHK(appFileInfo.SetTo(&file) == B_OK);
2269 CHK(appFileInfo.SetVersionInfo(NULL, B_APP_VERSION_KIND)
2273 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND)
2275 CHK(appFileInfo.GetVersionInfo(&info, B_SYSTEM_VERSION_KIND)
2282 CHK(appFileInfo.SetVersionInfo(&testInfo1, B_APP_VERSION_KIND)
2284 CHK(appFileInfo.SetVersionInfo(&testInfo1, B_SYSTEM_VERSION_KIND)
2287 CHK(appFileInfo.SetVersionInfo(NULL, B_SYSTEM_VERSION_KIND) == B_OK);
2289 CHK(appFileInfo.GetVersionInfo(&info, B_APP_VERSION_KIND)
2291 CHK(appFileInfo.GetVersionInfo(&info, B_SYSTEM_VERSION_KIND)
2303 CHK(appFileInfo.SetVersionInfo(&testInfo1, B_APP_VERSION_KIND)
2305 CHK(appFileInfo.GetVersionInfo(&testInfo1, B_SYSTEM_VERSION_KIND)
2321 CHK(appFileInfo.SetTo(&file) == B_OK);
2322 CHK(appFileInfo.GetIconForType(testType1, NULL, B_MINI_ICON)
2324 CHK(appFileInfo.GetIconForType(testType1, NULL, B_LARGE_ICON)
2332 CHK(appFileInfo.GetIconForType(testType1, &icon, B_MINI_ICON)
2335 CHK(appFileInfo.GetIconForType(testType1, &icon2, B_LARGE_ICON)
2343 CHK(appFileInfo.SetTo(&file) == B_OK);
2345 CHK(appFileInfo.GetIconForType(testType1, &icon, B_MINI_ICON)
2348 CHK(appFileInfo.GetIconForType(testType1, &icon2, B_LARGE_ICON)
2356 CHK(appFileInfo.SetTo(&file) == B_OK);
2358 CHK(appFileInfo.GetIconForType(testType1, &icon, B_MINI_ICON)
2366 CHK(appFileInfo.SetTo(&file) == B_OK);
2369 CHK(appFileInfo.SetIconForType(testType1, fIconM1, B_MINI_ICON)
2373 CHK(appFileInfo.GetIconForType(testType1, &icon, B_MINI_ICON) == B_OK);
2374 CHK(icon_equal(fIconM1, &icon));
2379 CHK(appFileInfo.SetIconForType(testType1, fIconM2, B_MINI_ICON)
2383 CHK(appFileInfo.GetIconForType(testType1, &icon2, B_MINI_ICON)
2385 CHK(icon_equal(fIconM2, &icon2));
2391 CHK(appFileInfo.SetIconForType(testType1, fIconL1, B_LARGE_ICON)
2395 CHK(appFileInfo.GetIconForType(testType1, &icon3, B_LARGE_ICON)
2397 CHK(icon_equal(fIconL1, &icon3));
2402 CHK(appFileInfo.SetIconForType(testType1, fIconL2, B_LARGE_ICON)
2406 CHK(appFileInfo.GetIconForType(testType1, &icon4, B_LARGE_ICON)
2408 CHK(icon_equal(fIconL2, &icon4));
2418 CHK(appFileInfo.SetTo(&file) == B_OK);
2421 CHK(appFileInfo.GetIconForType(testType1, &icon, B_MINI_ICON) == B_OK);
2425 CHK(icon_equal(&icon, &icon2));
2430 CHK(appFileInfo.GetIconForType(testType1, &icon3, B_LARGE_ICON)
2435 CHK(icon_equal(&icon3, &icon4));
2446 CHK(appFileInfo.SetTo(&file) == B_OK);
2449 CHK(appFileInfo.SetIconForType(testType1, NULL, B_MINI_ICON) == B_OK);
2452 CHK(appFileInfo.GetIconForType(testType1, &icon, B_MINI_ICON)
2459 CHK(appFileInfo.SetIconForType(testType1, NULL, B_LARGE_ICON) == B_OK);
2462 CHK(appFileInfo.GetIconForType(testType1, &icon2, B_LARGE_ICON)
2473 CHK(appFileInfo.SetIconForType(testType1, &icon, B_MINI_ICON)
2476 CHK(appFileInfo.SetIconForType(testType1, &icon2, B_LARGE_ICON)
2484 CHK(appFileInfo.SetTo(&file) == B_OK);
2486 CHK(appFileInfo.SetIconForType(testType1, &icon, B_MINI_ICON)
2489 CHK(appFileInfo.SetIconForType(testType1, &icon2, B_LARGE_ICON)
2497 CHK(appFileInfo.SetTo(&file) == B_OK);
2498 CHK(appFileInfo.SetIconForType(NULL, fIconM1, B_MINI_ICON) == B_OK);
2499 CHK(appFileInfo.SetIconForType(NULL, fIconL1, B_LARGE_ICON) == B_OK);
2502 CHK(appFileInfo.GetIcon(&icon, B_MINI_ICON) == B_OK);
2503 CHK(icon_equal(fIconM1, &icon));
2509 CHK(appFileInfo.GetIcon(&icon2, B_LARGE_ICON) == B_OK);
2510 CHK(icon_equal(fIconL1, &icon2));
2516 CHK(appFileInfo.GetIconForType(NULL, &icon3, B_MINI_ICON) == B_OK);
2517 CHK(icon_equal(fIconM1, &icon3));
2523 CHK(appFileInfo.GetIconForType(NULL, &icon4, B_LARGE_ICON) == B_OK);
2524 CHK(icon_equal(fIconL1, &icon4));
2534 CHK(appFileInfo.SetTo(&file) == B_OK);
2536 CHK(appFileInfo.SetIconForType(testType1, fIconM1, B_MINI_ICON)
2538 CHK(appFileInfo.SetIconForType(testType1, fIconL1, B_LARGE_ICON)
2540 CHK(appFileInfo.SetIconForType(testType2, fIconM2, B_MINI_ICON)
2542 CHK(appFileInfo.SetIconForType(testType2, fIconL2, B_LARGE_ICON)
2547 CHK(appFileInfo.GetIconForType(testType1, &icon, B_MINI_ICON)
2549 CHK(icon_equal(fIconM1, &icon));
2555 CHK(appFileInfo.GetIconForType(testType1, &icon2, B_LARGE_ICON)
2557 CHK(icon_equal(fIconL1, &icon2));
2564 CHK(appFileInfo.GetIconForType(testType2, &icon3, B_MINI_ICON)
2566 CHK(icon_equal(fIconM2, &icon3));
2573 CHK(appFileInfo.GetIconForType(testType2, &icon4, B_LARGE_ICON)
2575 CHK(icon_equal(fIconL2, &icon4));
2581 CHK(appFileInfo.SetIconForType(testType1, NULL, B_MINI_ICON) == B_OK);
2582 CHK(appFileInfo.SetIconForType(testType1, NULL, B_LARGE_ICON) == B_OK);
2583 CHK(appFileInfo.SetIconForType(testType2, NULL, B_MINI_ICON) == B_OK);
2584 CHK(appFileInfo.SetIconForType(testType2, NULL, B_LARGE_ICON) == B_OK);
2591 CHK(appFileInfo.SetTo(&file) == B_OK);
2592 CHK(appFileInfo.SetIconForType(invalidTestType, fIconM1, B_MINI_ICON)
2594 CHK(appFileInfo.SetIconForType(invalidTestType, fIconL1, B_LARGE_ICON)
2598 CHK(appFileInfo.GetIconForType(invalidTestType, &icon, B_MINI_ICON)
2604 CHK(appFileInfo.GetIconForType(invalidTestType, &icon3, B_LARGE_ICON)
2614 CHK(appFileInfo.SetTo(&file) == B_OK);
2615 CHK(appFileInfo.SetIconForType(tooLongTestType, fIconM1, B_MINI_ICON)
2617 CHK(appFileInfo.SetIconForType(tooLongTestType, fIconL1, B_LARGE_ICON)
2626 CHK(appFileInfo.SetTo(&file) == B_OK);
2629 CHK(mimeType.IsInstalled() == false);
2630 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
2631 CHK(appFileInfo.SetIconForType(testType1, fIconM1, B_MINI_ICON)
2633 CHK(appFileInfo.SetIconForType(testType1, fIconL1, B_LARGE_ICON)
2635 CHK(mimeType.IsInstalled() == true);
2636 CHK(BMimeType(testType1).IsInstalled() == false);
2639 CHK(mimeType.GetIconForType(testType1, &icon, B_MINI_ICON)
2641 CHK(icon_equal(fIconM1, &icon));
2644 CHK(mimeType.GetIconForType(testType1, &icon2, B_LARGE_ICON)
2646 CHK(icon_equal(fIconL1, &icon2));
2648 CHK(appFileInfo.SetIconForType(testType1, fIconM2, B_MINI_ICON)
2650 CHK(appFileInfo.SetIconForType(testType1, fIconL2, B_LARGE_ICON)
2654 CHK(mimeType.GetIconForType(testType1, &icon3, B_MINI_ICON)
2656 CHK(icon_equal(fIconM2, &icon3));
2659 CHK(mimeType.GetIconForType(testType1, &icon4, B_LARGE_ICON)
2661 CHK(icon_equal(fIconL2, &icon4));
2675 CHK(appFileInfo.SetTo(&file) == B_OK);
2676 CHK(appFileInfo.InitCheck() == B_OK);
2677 CHK(appFileInfo.IsUsingAttributes() == true);
2678 CHK(appFileInfo.IsUsingResources() == true);
2680 CHK(Setter::Set(appFileInfo, testValue1) == B_OK);
2681 CHK(appFileInfo.IsUsingAttributes() == true);
2682 CHK(appFileInfo.IsUsingResources() == true);
2687 CHK(Getter::Get(appFileInfo, value) == B_OK);
2688 CHK(value == testValue1);
2694 CHK(appFileInfo.IsUsingAttributes() == true);
2695 CHK(appFileInfo.IsUsingResources() == false);
2697 CHK(Setter::Set(appFileInfo, testValue2) == B_OK);
2702 CHK(Getter::Get(appFileInfo, value1) == B_OK);
2703 CHK(value1 == testValue2);
2709 CHK(appFileInfo.IsUsingAttributes() == true);
2710 CHK(appFileInfo.IsUsingResources() == true);
2713 CHK(Getter::Get(appFileInfo, value2) == B_OK);
2714 CHK(value2 == testValue2);
2717 CHK(appFileInfo.IsUsingAttributes() == false);
2718 CHK(appFileInfo.IsUsingResources() == true);
2720 CHK(Setter::Set(appFileInfo, testValue3) == B_OK);
2725 CHK(Getter::Get(appFileInfo, value3) == B_OK);
2726 CHK(value3 == testValue3);
2768 CHK(appFileInfo.SetTo(&file) == B_OK);
2769 CHK(appFileInfo.SetSignature(testAppSignature1) == B_OK);
2772 CHK(type.Install() == B_OK);