| 766 | |
| 767 | #[test] |
| 768 | fn test_pristine_open() { |
| 769 | let dir = tempdir().unwrap(); |
| 770 | let db_path = dir.path().join("pristine"); |
| 771 | let pristine = Pristine::open(&db_path).unwrap(); |
| 772 | |
| 773 | assert_eq!( |
| 774 | pristine.path_claim_schema_version().unwrap(), |
| 775 | Some(PATH_CLAIM_SCHEMA_VERSION) |
| 776 | ); |
| 777 | assert!(!pristine.path_claim_migration_required().unwrap()); |
| 778 | |
| 779 | // Should be able to create transactions |
| 780 | let _read = pristine.read_txn().unwrap(); |
| 781 | let _write = pristine.write_txn().unwrap(); |
| 782 | } |
| 783 | |
| 784 | fn metadata_only_repository_with_requirement(db_path: &Path, capability: &str, version: u32) { |
| 785 | let db = Database::create(db_path).unwrap(); |