// XMLSignatureValidator_as.hx:  ActionScript 3 "XMLSignatureValidator" class, for Gnash.
//
// Generated by gen-as3.sh on: 20090515 by "rob". Remove this
// after any hand editing loosing changes.
//
//   Copyright (C) 2009 Free Software Foundation, Inc.
//
// This program is free software; you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation; either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
//

// This test case must be processed by CPP before compiling to include the
//  DejaGnu.hx header file for the testing framework support.

#if flash9
import flash.security.XMLSignatureValidator;
import flash.display.MovieClip;
#else
import flash.XMLSignatureValidator;
import flash.MovieClip;
#end
import flash.Lib;
import Type;

// import our testing API
import DejaGnu;

// Class must be named with the _as suffix, as that's the same name as the file.
class XMLSignatureValidator_as {
    static function main() {
        var x1:XMLSignatureValidator = new XMLSignatureValidator();

        // Make sure we actually get a valid class        
        if (x1 != null) {
            DejaGnu.pass("XMLSignatureValidator class exists");
        } else {
            DejaGnu.fail("XMLSignatureValidator class doesn't exist");
        }
// Tests to see if all the properties exist. All these do is test for
// existance of a property, and don't test the functionality at all. This
// is primarily useful only to test completeness of the API implementation.
	if (x1.digestStatus == null) {
	    DejaGnu.pass("XMLSignatureValidator.digestStatus property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.digestStatus property doesn't exist");
	}
	if (x1.identityStatus == null) {
	    DejaGnu.pass("XMLSignatureValidator.identityStatus property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.identityStatus property doesn't exist");
	}
	if (x1.referencesStatus == null) {
	    DejaGnu.pass("XMLSignatureValidator.referencesStatus property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.referencesStatus property doesn't exist");
	}
	if (x1.revocationCheckSetting == null) {
	    DejaGnu.pass("XMLSignatureValidator.revocationCheckSetting property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.revocationCheckSetting property doesn't exist");
	}
	if (x1.signerCN == null) {
	    DejaGnu.pass("XMLSignatureValidator.signerCN property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.signerCN property doesn't exist");
	}
	if (x1.signerDN == null) {
	    DejaGnu.pass("XMLSignatureValidator.signerDN property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.signerDN property doesn't exist");
	}
	if (x1.signerExtendedKeyUsages == 0) {
	    DejaGnu.pass("XMLSignatureValidator.signerExtendedKeyUsages property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.signerExtendedKeyUsages property doesn't exist");
	}
	if (x1.signerTrustSettings == 0) {
	    DejaGnu.pass("XMLSignatureValidator.signerTrustSettings property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.signerTrustSettings property doesn't exist");
	}
	if (x1.uriDereferencer == uriDereferencer) {
	    DejaGnu.pass("XMLSignatureValidator.uriDereferencer property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.uriDereferencer property doesn't exist");
	}
	if (x1.useSystemTrustStore == false) {
	    DejaGnu.pass("XMLSignatureValidator.useSystemTrustStore property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.useSystemTrustStore property doesn't exist");
	}
	if (x1.validityStatus == null) {
	    DejaGnu.pass("XMLSignatureValidator.validityStatus property exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator.validityStatus property doesn't exist");
	}

// Tests to see if all the methods exist. All these do is test for
// existance of a method, and don't test the functionality at all. This
// is primarily useful only to test completeness of the API implementation.
	if (x1.XMLSignatureValidator == XMLSignatureValidator) {
	    DejaGnu.pass("XMLSignatureValidator::XMLSignatureValidator() method exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator::XMLSignatureValidator() method doesn't exist");
	}
	if (x1.addCertificate == *) {
	    DejaGnu.pass("XMLSignatureValidator::addCertificate() method exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator::addCertificate() method doesn't exist");
	}
	if (x1.verify == null) {
	    DejaGnu.pass("XMLSignatureValidator::verify() method exists");
	} else {
	    DejaGnu.fail("XMLSignatureValidator::verify() method doesn't exist");
	}

        // Call this after finishing all tests. It prints out the totals.
        DejaGnu.done();
    }
}

// local Variables:
// mode: C++
// indent-tabs-mode: t
// End:

