Did I find the right examples for you? yes no

All Samples(2)  |  Call(1)  |  Derive(0)  |  Import(1)
FedEx service configuration. The service configuration may be provided
directly via parameter values, or it can be read from a configuration file.
If no parameters are given, the configuration will attempt to read from a
``'.fedex.cfg'`` file in the user's HOME directory. Alternately, a
configuration filename can be passed to the constructor.

Here is a sample configuration (by default the constructor reads from a
``'default'`` section):


src/f/e/fedex.py-0.3.2/fedex/tests.py   fedex.py(Download)
from .config import FedexConfiguration
from .services import (FedexService, AddressService, RateService,
        ShipmentService, TrackingService)
directory_path = os.path.dirname(file_path)
file_name = os.path.join(directory_path, "tests.cfg")
CONFIGURATION = FedexConfiguration(wsdls="beta", file_name=file_name)
    def test_address_service(self):
        """Test the address service.
        service = AddressService(CONFIGURATION)
        address = service.create_address()
    def test_rate_service(self):
        """Test the rate service.
        service = RateService(CONFIGURATION)
        shipment = service.create_shipment()
    def test_shipment_service(self):
        """Test the shipment service.
        service = ShipmentService(CONFIGURATION)
        shipment = service.create_shipment()