You're going to have to inspect each junction and device in the circuit, starting with the first know bad device. It sounds like you have a GFCI in the house, which feeds a receptacle in the shed, which in turn feeds a switched light in the shed. Since the receptacle in the shed is the first know bad device, you'll want to start there.
Turn off the power at the circuit breaker. Pull the receptacle out of the box, leaving the wires connected. Inspect the wiring for loose connections, and fix any found. If there where no loose connections, you'll want to determine which wires entering the box feed the receptacle. If this is not obvious, you'll have to do some testing. For this you'll need a multimeter with a continuity function. Disconnect one of the neutral (White) wires from the receptacle, set the multimeter to test continuity, touch one probe to the equipment ground, touch the other to the disconnected neutral, then to the still connected neutral. If one tests positive (audible tone, or reading on display), that is the feed line. If neither or both test positive, you'll have to do testing with the power on (which I won't cover here since it is unsafe, and you should call an Electrician at this point).
Now that you've found your line wires, reconnect the neutral to the receptacle. Leave the receptacle out of the box; making sure nothing is in contact with the edge of the box, then turn the power back on. Turn the light on in the shed. If it goes out, use a non-contact voltage tester to test for voltage. If you have voltage on the line but not the load, replace the receptacle. If you have voltage at neither point, run similar tests on the GFCI receptacle.
If you have voltage on the load side of the GFCI, but no voltage on the line side of the receptacle in the shed. You'll have to inspect the wires connecting the two devices. Start by shutting off the power, at the breaker. Next disconnect the load wires from the GFCI, and the line wires at the receptacle. Run a continuity test between all combinations of the wires, none should test positive. Finally connect one pair of wires at one end (so in the shed, twist the black and white wires together), do a continuity test on the other end to make sure the circuit is not open.
If all of this has been done, and the problem persists, you'll want to contact an Electrician.
As always, if you don't have the proper tools, or you don't feel comfortable doing any of the work mentioned. Do not hesitate to contact a local licensed Electrician.
Residential Kitchen
In a dwelling unit (residential), GFCI protection is only required for kitchen receptacles that serve the countertop surfaces. There's no requirement to GFCI protect receptacles that serve a refrigerator. Unless the fridge is plugged into a countertop receptacle.
National Electrical Code 2014
Chapter 2 Wiring and Protection
Article 210 Branch Circuits
I. General Provisions
210.8 Ground-Fault Circuit-Interrupter Protection for Personnel. Ground-fault circuit-interrupter protection for personnel shall be provided as required in 210.8(A) through (C). The ground-fault circuit-interrupter shall be installed in a readily accessible location.
(A) Dwelling Units. All 125-volt, single-phase, 15- and
20-ampere receptacles installed in the locations specified in
210.8(A)(1) through (10) shall have ground-fault circuit interrupter protection for personnel.
(6) Kitchens— where the receptacles are installed to serve the countertop surfaces.
Garages, Unfinished Basement, and Other Locations
If the refrigerator is in a garage, boathouse, or unfinished basement. All the receptacles are required to be GFCI protected, so the fridge will have to be plugged into a GFCI protected receptacle.
Why does the fridge trip the GFCI?
Any inductive load when switched off, can produce electromagnetic interference (EMI). This interference can, and often does, trip GFCI devices. Most vapor compression refrigerators have a few inductive loads, any of which could cause the trip.
Is there anything that can be done?
There are devices called snubbers that can be used to reduce, or eliminate the effects of EMI. Installing one between the fridge and the GFCI device, could prevent nuisance trips. The best solution though, is to connect the fridge to a non-GFCI protected circuit.
If that's all it takes, why isn't there already one built in?
While most (all) manufacturers are aware that refrigerators can cause nuisance tripping of GFCI devices, most (none) seem willing to provide a solution. It would be complete speculation for me to try and tell you why they don't care, so of course I'll go through a few possibilities.
- Cost.
Plain and simple, it costs money to implement a solution.
- Warranties and Operating Conditions.
Most refrigerators are designed to operate in a kitchen. Running them in dusty, dirty garages and basements could lead to more warranty covered repairs.
Best Answer
Defrost Cycle
As discussed in comments, this problem does not happen immediately but appears to be related to the defrost cycle - in one test it took 7 hours until the breaker tripped. Assuming this is the GFCI tripping, which appears to be the case though that hasn't been stated clearly, that points to one of two possible problems:
So the question becomes: Is this the beginning of a potentially dangerous fault, in which case the GFCI may have saved someone from serious, even fatal, electrocution, or is this truly a minor issue, possibly even a design flaw, where the electrical leakage is so small and so hidden that it would never actually present a danger.
As Harper frequently points out, GFCI trips on refrigerators generally have far more risk of causing food poisoning and/or loss of food due to undetected problems than they do of benefit by preventing electrocution. So if the situation really is "not a real problem, just poor design that leads to GFCI trips every defrost cycle but safe to use" then the solution is to wire up a refrigerator-only receptacle off the LINE side of the GFCI instead of the LOAD side.
If, on the other hand, this problem is actually a sign of a potentially dangerous situation - perhaps caused by damage during the 5 years that the refrigerator sat unused - then fixing the underlying problem is a much better course of action.
No random person on the internet can make this potential life-safety decision for you.
(If it were me, I'd see if I could isolate the components of the defrost circuit to see if there was repairable damage. But that's me. And it is likely a non-trivial project to do that.)