# Path: duplicity/globals.py



import config
import sys, unittest
from duplicity import dup_time
from duplicity import file_naming
from duplicity import log
from duplicity import globals
        assert pr.type == "full-sig"
        assert pr.time == 20
        assert not pr.partial

        filename = file_naming.get("new-sig")
        pr = file_naming.parse(filename)
        assert pr.type == "new-sig"
        assert pr.start_time == 10
        assert pr.end_time == 20
        assert not pr.partial

    def test_suffix(self):
        """Test suffix (encrypt/compressed) encoding and generation"""
        filename = file_naming.get("inc", manifest = 1, gzipped = 1)
        pr = file_naming.parse(filename)
        assert pr and pr.compressed == 1
        assert pr.manifest

        filename2 = file_naming.get("full", volume_number = 23, encrypted = 1)
        pr = file_naming.parse(filename2)
        assert pr and pr.encrypted == 1
        assert pr.volume_number == 23

    def test_more(self):
        """More file_parsing tests"""
        pr = file_naming.parse("dns.h112bi.h14rg0.st.g")
        assert pr, pr
        assert pr.type == "new-sig"
        assert pr.end_time == 1029826800L


# Path: duplicity/globals.py



# Path: testing/file_namingtest.py
import config
import sys, unittest
from duplicity import dup_time
from duplicity import file_naming
from duplicity import log
from duplicity import globals

        assert pr.type == "full-sig"
        assert pr.time == 20
        assert not pr.partial

        filename = file_naming.get("new-sig")
        pr = file_naming.parse(filename)
        assert pr.type == "new-sig"
        assert pr.start_time == 10
        assert pr.end_time == 20
        assert not pr.partial

    def test_suffix(self):
        """Test suffix (encrypt/compressed) encoding and generation"""
        filename = file_naming.get("inc", manifest = 1, gzipped = 1)
        pr = file_naming.parse(filename)
        assert pr and pr.compressed == 1
        assert pr.manifest

        filename2 = file_naming.get("full", volume_number = 23, encrypted = 1)
        pr = file_naming.parse(filename2)
        assert pr and pr.encrypted == 1
        assert pr.volume_number == 23

    def test_more(self):
        """More file_parsing tests"""
        pr = file_naming.parse("dns.h112bi.h14rg0.st.g")
        assert pr, pr
        assert pr.type == "new-sig"
        assert pr.end_time == 1029826800L


        if not globals.short_filenames: