Which court? I want to say it has happened in California and it did hold up.
I agree, I recall reading some case law summary that was similar. If I get a chance tomorrow, I'll look for it.
In the meantime, Please find the below attached for your reading pleasure. Keep in mind "On a public highway or roadway" does not mean the vehicle has to be moving or in traffic lanes. The CVC defines Highway and Roadway differently. Also, keep in mind there are additional sections of the CVC, penal code, county and local ordinance, and Business and Professions Code which also restrict behaviors, including drinking in public, public intoxication, minor in possession of alcohol, etc.
360. "Highway" is a way or place of whatever nature, publicly
maintained and open to the use of the public for purposes of
vehicular travel. Highway includes street
530. A "roadway" is that portion of a highway improved, designed,
or ordinarily used for vehicular travel
23221. (a) No driver shall drink any alcoholic beverage while in a
motor vehicle upon a highway.
(b) No passenger shall drink any alcoholic beverage while in a
motor vehicle upon a highway.
This means even while parked along the curb. See definition of Highway above.
23222. (a) No person shall have in his or her possession on his or
her person, while driving a motor vehicle upon a highway or on lands,
as described in subdivision (b) of Section 23220, any bottle, can,
or other receptacle, containing any alcoholic beverage which has been
opened, or a seal broken, or the contents of which have been
partially removed.
(b) Except as authorized by law, every person who possesses, while
driving a motor vehicle upon a highway or on lands, as described in
subdivision (b) of Section 23220, not more than one avoirdupois ounce
of marijuana, other than concentrated cannabis as defined by Section
11006.5 of the Health and Safety Code, is guilty of a misdemeanor
and shall be punished by a fine of not more than one hundred dollars
($100). Notwithstanding any other provision of law, if the person has
been previously convicted three or more times of an offense
described in this subdivision during the two-year period immediately
preceding the date of commission of the violation to be charged, the
previous convictions shall also be charged in the accusatory pleading
and, if found to be true by the jury upon a jury trial or by the
court upon a court trial or if admitted by the person, Sections
1000.1 and 1000.2 of the Penal Code are applicable to the person, and
the court shall divert and refer the person for education,
treatment, or rehabilitation, without a court hearing or
determination or the concurrence of the district attorney, to an
appropriate community program which will accept the person. If the
person is so diverted and referred, the person is not subject to the
fine specified in this subdivision. In any case in which a person is
arrested for a violation of this subdivision and does not demand to
be taken before a magistrate, the person shall be released by the
arresting officer upon presentation of satisfactory evidence of
identity and giving his or her written promise to appear in court, as
provided in Section 40500, and shall not be subjected to booking.
23223. (a) No driver shall have in his or her possession, while in
a motor vehicle upon a highway or on lands, as described in
subdivision (b) of Section 23220, any bottle, can, or other
receptacle, containing any alcoholic beverage that has been opened,
or a seal broken, or the contents of which have been partially
removed.
(b) No passenger shall have in his or her possession, while in a
motor vehicle upon a highway or on lands, as described in subdivision
(b) of Section 23220, any bottle, can, or other receptacle
containing any alcoholic beverage that has been opened or a seal
broken, or the contents of which have been partially removed.
23224. (a) No person under the age of 21 years shall knowingly
drive any motor vehicle carrying any alcoholic beverage, unless the
person is accompanied by a parent, responsible adult relative, any
other adult designated by the parent, or legal guardian for the
purpose of transportation of an alcoholic beverage, or is employed by
a licensee under the Alcoholic Beverage Control Act (Division 9
(commencing with Section 23000) of the Business and Professions
Code), and is driving the motor vehicle during regular hours and in
the course of the person's employment. If the driver was
unaccompanied, he or she shall have a complete defense if he or she
was following, in a timely manner, the reasonable instructions of his
or her parent, legal guardian, responsible adult relative, or adult
designee relating to disposition of the alcoholic beverage.
(b) No passenger in any motor vehicle who is under the age of 21
years shall knowingly possess or have under that person's control any
alcoholic beverage, unless the passenger is accompanied by a parent,
legal guardian, responsible adult relative, any other adult
designated by the parent, or legal guardian for the purpose of
transportation of an alcoholic beverage, or is employed by a licensee
under the Alcoholic Beverage Control Act (Division 9 (commencing
with Section 23000) of the Business and Professions Code), and
possession or control is during regular hours and in the course of
the passenger's employment. If the passenger was unaccompanied, he or
she shall have a complete defense if he or she was following, in a
timely manner, the reasonable instructions of his or her parent,
legal guardian, responsible adult relative or adult designee relating
to disposition of the alcoholic beverage.
(c) If the vehicle used in any violation of subdivision (a) or (b)
is registered to an offender who is under the age of 21 years, the
vehicle may be impounded at the owner's expense for not less than one
day nor more than 30 days for each violation.
(d) Any person under 21 years of age convicted of a violation of
this section is subject to Section 13202.5.
(e) Any person convicted for a violation of subdivision (a) or (b)
is guilty of a misdemeanor and shall be punished upon conviction by
a fine of not more than one thousand dollars ($1,000) or by
imprisonment in the county jail for not more than six months, or by
both that fine and imprisonment.
23225. (a) (1) It is unlawful for the registered owner of any motor
vehicle to keep in a motor vehicle, when the vehicle is upon any
highway or on lands, as described in subdivision (b) of Section
23220, any bottle, can, or other receptacle containing any alcoholic
beverage that has been opened, or a seal broken, or the contents of
which have been partially removed, unless the container is kept in
the trunk of the vehicle.
(2) If the vehicle is not equipped with a trunk and is not an
off-highway motor vehicle subject to identification, as defined in
Section 38012, the bottle, can, or other receptacle described in
paragraph (1) shall be kept in some other area of the vehicle that is
not normally occupied by the driver or passengers. For the purposes
of this paragraph, a utility compartment or glove compartment shall
be deemed to be within the area occupied by the driver and
passengers.
(3) If the vehicle is not equipped with a trunk and is an
off-highway motor vehicle subject to identification, as defined in
subdivision (a) of Section 38012, the bottle, can, or other
receptacle described in paragraph (1) shall be kept in a locked
container. As used in this paragraph, "locked container" means a
secure container that is fully enclosed and locked by a padlock, key
lock, combination lock, or similar locking device.
(b) Subdivision (a) is also applicable to a driver of a motor
vehicle if the registered owner is not present in the vehicle.
(c) This section shall not apply to the living quarters of a
housecar or camper.