!C99Shell v. 1.0 pre-release build #16!

Software: Apache/2.0.54 (Fedora). PHP/5.0.4 

uname -a: Linux mina-info.me 2.6.17-1.2142_FC4smp #1 SMP Tue Jul 11 22:57:02 EDT 2006 i686 

uid=48(apache) gid=48(apache) groups=48(apache)
context=system_u:system_r:httpd_sys_script_t
 

Safe-mode: OFF (not secure)

/usr/lib/4Suite/tests/Server/Server/Xslt/   drwxr-xr-x
Free 1.7 GB of 27.03 GB (6.29%)
Home    Back    Forward    UPDIR    Refresh    Search    Buffer    Encoder    Tools    Proc.    FTP brute    Sec.    SQL    PHP-code    Update    Feedback    Self remove    Logout    


Viewing file:     test_model.py (2.41 KB)      -rw-r--r--
Select action/file-type:
(+) | (+) | (+) | Code (+) | Session (+) | (+) | SDB (+) | (+) | (+) | (+) | (+) | (+) |


import test_helper

from Ft.Server.Common import DocumentReference, ResourceTypes

def test_complete_function(tester):

    sty = """<?xml version="1.0"?>
<xsl:stylesheet
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
  xmlns:fcore='http://xmlns.4suite.org/4ss/score'
  xmlns:frdf='http://xmlns.4suite.org/4ss/rdf'
  extension-element-prefixes="fcore frdf"
  >
  <xsl:output method='xml'/>
  <xsl:template match="/">
    <xsl:copy-of select='frdf:complete("/test","http://www.w3.org/1999/02/22-rdf-syntax-ns#type",frdf:any())'/>
  </xsl:template>
</xsl:stylesheet>"""

    expected = """<?xml version='1.0' encoding='UTF-8'?>\n<Statement><Subject>/test</Subject><Predicate>http://www.w3.org/1999/02/22-rdf-syntax-ns#type</Predicate><Object>http://schemas.4suite.org/4ss#container</Object></Statement>"""

    tester.startTest("XSLT Extension RDF Complete")

    repo = test_helper.GetRepo(tester)

    test = repo.fetchResource('test')
    test_helper.TestXslt(tester,test,sty,expected)
    repo.txCommit()

    tester.testDone()


def test_complete_element(tester):

    sty = """<?xml version="1.0"?>
<xsl:stylesheet
  xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"
  xmlns:fcore='http://xmlns.4suite.org/4ss/score'
  xmlns:frdf='http://xmlns.4suite.org/4ss/rdf'
  extension-element-prefixes="fcore frdf"
  >
  <xsl:output method='xml'/>
  <xsl:template match="/">
    <frdf:complete s='/test' p = 'http://www.w3.org/1999/02/22-rdf-syntax-ns#type'/>
  </xsl:template>
</xsl:stylesheet>"""

   expected = """<?xml version='1.0' encoding='UTF-8'?>\n<Statement><Subject>/test</Subject><Predicate>http://www.w3.org/1999/02/22-rdf-syntax-ns#type</Predicate><Object>http://schemas.4suite.org/4ss#container</Object><StatementUri></StatementUri><SourceUri>http://schemas.4suite.org/4ss#system</SourceUri></Statement>"""

    tester.startTest("XSLT Extension RDF Complete Element")

    repo = test_helper.GetRepo(tester)

    test = repo.fetchResource('test')
    test_helper.TestXslt(tester,test,sty,expected)
    repo.txCommit()

    tester.testDone()


def cleanup(tester):

    tester.startTest("Clean Up")
    repo = test_helper.GetRepo(tester)
    if repo.hasResource('/test'):
        t = repo.fetchResource('/test')
        t.delete()
    
    repo.createContainer('test')
    repo.txCommit()
    tester.testDone()




def Test(tester):

    cleanup(tester)
    test_complete_function(tester)
    test_complete_element(tester)


:: Command execute ::

Enter:
 
Select:
 

:: Search ::
  - regexp 

:: Upload ::
 
[ Read-Only ]

:: Make Dir ::
 
[ Read-Only ]
:: Make File ::
 
[ Read-Only ]

:: Go Dir ::
 
:: Go File ::
 

--[ c99shell v. 1.0 pre-release build #16 powered by Captain Crunch Security Team | http://ccteam.ru | Generation time: 0.0036 ]--