Two vials tested from a lot of ten is very different from two vials tested from a lot of ten thousand, and most certificates do not state the lot size.
Testing a vial that has been open in the lab for three months is testing aged material, not the fresh lot, and the result should be explicitly noted as a retest.
Acceptance Sampling by Attributes defines the number of samples you need from a lot to claim a specified quality level at a specified risk — it is in ANSI standard Z1.4.
Sampling plans for pharmaceutical manufacturing are defined in ISO 2859 and ANSI Z1.4, and they are based on statistical sampling theory.
Assume segregation is possible, and design your sampling to catch it if it exists.
edited 3 Jul 2025 by charge_state_3 — corrected a unit error in the worked example