Skip to content

Commit

Permalink
chore: update formula path (#1614)
Browse files Browse the repository at this point in the history
  • Loading branch information
kmruiz authored Aug 24, 2023
1 parent 6c75482 commit 6bcde16
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion packages/build/src/homebrew/generate-formula.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ describe('Homebrew generate-formula', function () {

beforeEach(function () {
getFileContent = sinon.stub();
getFileContent.withArgs('Formula/mongosh.rb', 'master').resolves({
getFileContent.withArgs('Formula/m/mongosh.rb', 'master').resolves({
blobSha: 'blobSha',
content: VALID_FORMULA,
});
Expand Down
2 changes: 1 addition & 1 deletion packages/build/src/homebrew/generate-formula.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export async function generateUpdatedFormula(
isDryRun: boolean
): Promise<string | null> {
const currentFormula = await homebrewCore.getFileContent(
'Formula/mongosh.rb',
'Formula/m/mongosh.rb',
'master'
);

Expand Down
6 changes: 3 additions & 3 deletions packages/build/src/homebrew/update-homebrew-fork.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ describe('Homebrew update-homebrew-fork', function () {
});

it('writes updated formula and pushes changes', async function () {
getFileContent.rejects().withArgs('Formula/mongosh.rb').resolves({
getFileContent.rejects().withArgs('Formula/m/mongosh.rb').resolves({
blobSha: 'sha1',
content: 'old formula',
});
Expand All @@ -53,7 +53,7 @@ describe('Homebrew update-homebrew-fork', function () {
.withArgs(
'mongosh 1.0.0',
'sha1',
'Formula/mongosh.rb',
'Formula/m/mongosh.rb',
'updated formula',
'mongosh-1.0.0-sha'
)
Expand All @@ -76,7 +76,7 @@ describe('Homebrew update-homebrew-fork', function () {
});

it('does not push changes if formula is same', async function () {
getFileContent.rejects().withArgs('Formula/mongosh.rb').resolves({
getFileContent.rejects().withArgs('Formula/m/mongosh.rb').resolves({
blobSha: 'sha1',
content: 'formula',
});
Expand Down
2 changes: 1 addition & 1 deletion packages/build/src/homebrew/update-homebrew-fork.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export async function updateHomebrewFork(
params: UpdateHomebrewParameters
): Promise<string | undefined> {
const branchName = `mongosh-${params.packageVersion}-${params.packageSha}`;
const formulaPath = 'Formula/mongosh.rb';
const formulaPath = 'Formula/m/mongosh.rb';

const { content: currentContent, blobSha } =
await params.homebrewCore.getFileContent(formulaPath, 'master');
Expand Down

0 comments on commit 6bcde16

Please sign in to comment.