From b0e7235f8b6fb146c3882b6c9ed27f7447e63404 Mon Sep 17 00:00:00 2001 From: Anthony Shoumikhin Date: Thu, 26 Jun 2025 15:41:00 -0700 Subject: [PATCH] Remove obsolete tests from LLaMaRunner. Summary: . Reviewed By: larryliu0820 Differential Revision: D77399901 --- .../LLaMARunner/__tests__/RunnerTest.swift | 34 ------------------- 1 file changed, 34 deletions(-) delete mode 100644 examples/demo-apps/apple_ios/LLaMA/LLaMARunner/LLaMARunner/__tests__/RunnerTest.swift diff --git a/examples/demo-apps/apple_ios/LLaMA/LLaMARunner/LLaMARunner/__tests__/RunnerTest.swift b/examples/demo-apps/apple_ios/LLaMA/LLaMARunner/LLaMARunner/__tests__/RunnerTest.swift deleted file mode 100644 index 7175ea42291..00000000000 --- a/examples/demo-apps/apple_ios/LLaMA/LLaMARunner/LLaMARunner/__tests__/RunnerTest.swift +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) Meta Platforms, Inc. and affiliates. - * All rights reserved. - * - * This source code is licensed under the BSD-style license found in the - * LICENSE file in the root directory of this source tree. - */ - -@testable import LLaMARunner - -import XCTest - -final class RunnerTest: XCTestCase { - - func test() { - let bundle = Bundle(for: type(of: self)) - guard let modelPath = bundle.path(forResource: "xnnpack_dq_llama2", ofType: "pte"), - let tokenizerPath = bundle.path(forResource: "flores200sacrebleuspm", ofType: "bin") else { - XCTFail("Couldn't find model or tokenizer files") - return - } - let runner = Runner(modelPath: modelPath, tokenizerPath: tokenizerPath) - var text = "" - - do { - try runner.generate("fr hello", sequenceLength: 128) { token in - text += token - } - } catch { - XCTFail("Failed to generate text with error \(error)") - } - XCTAssertTrue(["bonjour", "salut", "coucou"].map { $0.lowercased() }.contains { text.lowercased().contains($0) }) - } -}