emacs-eask / eask

Core Eask APIs, for Eask CLI development
GNU General Public License v3.0
17 stars 6 forks source link

How do I run tests without connecting to the internet? #6

Open Trevoke opened 1 week ago

Trevoke commented 1 week ago

This confuses me to no end:

% eask test buttercup
Adding required archives (melpa)... done ✓
Refresh archives information... done ✓
  - Skipping buttercup (20240904.2311)... already installed ✗
Running 3 specs.

Why on earth is it refreshing the archives information? How can I make it not do that?

jcs090218 commented 1 week ago

Eask needs to download buttercup before use. Without refreshing archive information (is equivalent to the function (package-refresh-contents)), Emacs doesn't know what packages and versions are available to download. 🤔

Trevoke commented 1 week ago

I understand this but it's happening every time I run eask run test. Surely it's able to check locally whether the package is installed?

--

Aldric. Sent from a mobile device.

On Wed, Nov 20, 2024, 23:47 Jen-Chieh Shen @.***> wrote:

Eask needs to download buttercup before use. Without refreshing archive information (is equivalent to the function (package-refresh-contents)), Emacs doesn't know what packages and versions are available to download. 🤔

— Reply to this email directly, view it on GitHub https://github.com/emacs-eask/eask/issues/6#issuecomment-2490070395, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAAQSSL4XYYLTRZA3GHEJML2BVQVDAVCNFSM6AAAAABSF7JKTGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDIOJQGA3TAMZZGU . You are receiving this because you authored the thread.Message ID: @.***>

Trevoke commented 1 week ago

For clarification, my use case is: I'd like to do TDD :)

Trevoke commented 1 week ago

Ok. I don't exactly understand what's happening but:

  1. I only have gnu as a dependency
  2. when I added melpa, it stopped doing the archive refresh
  3. I think this only happens if my package depends on a recipe
  4. I don't know what that means and how to stop it

So for now I can do TDD by just adding melpa as a source in the Eask file but that seems wrong :)

jcs090218 commented 1 week ago

I've opened a PR for this, see https://github.com/emacs-eask/cli/pull/284.

jcs090218 commented 1 week ago
  1. when I added melpa, it stopped doing the archive refresh

It's probably refreshed before the command tasks. 🤔

  1. I think this only happens if my package depends on a recipe

Depends on a recipe requires package-build to be installed, so it requires the melpa source.

jcs090218 commented 1 week ago

Can you try the latest version and see if that works? Thanks!