Skip to content

Commit

Permalink
Merge pull request #4 from seangwright/fix/ci
Browse files Browse the repository at this point in the history
Fix: CI pipeline
  • Loading branch information
seangwright authored Feb 14, 2024
2 parents 6994cef + 79eb78f commit d6d6882
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 17 deletions.
15 changes: 0 additions & 15 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,21 +35,6 @@ jobs:
steps:
- uses: actions/checkout@v4

- name: Replace Test Connection String
run: |
$jsonContent = Get-Content -Path "./src/${{ env.PROJECT_NAME }}/appsettings.CI.json" -Raw
$config = $jsonContent | ConvertFrom-Json
$ciConnectionString = $config.ConnectionStrings.CMSConnectionString
$files = Get-ChildItem -Path "./test" -Filter "Tests.config" -Recurse
foreach ($file in $files) {
$xml = [xml](Get-Content $file.FullName)
$connectionStringNode = $xml.SelectSingleNode("//add[@name='CMSTestConnectionString']")
$connectionStringNode.SetAttribute("connectionString", $ciConnectionString)
$xml.Save($file.FullName)
}
- name: "Get node.js version from package.json"
run: |
$nodeVersion = (Get-Content -Raw -Path ./src/${{ env.PROJECT_NAME }}/package.json | ConvertFrom-Json).engines.node
Expand Down
2 changes: 1 addition & 1 deletion test/Kentico.Community.Portal.Web.E2E.Tests/Tests.config
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<connectionStrings>
<add name="CMSTestConnectionString" connectionString="Data Source=localhost;Initial Catalog=Kentico.Community;Integrated Security=True;Persist Security Info=False;Connect Timeout=10;Encrypt=False;Current Language=English;"/>
<add name="CMSTestConnectionString" connectionString="Data Source=localhost;Initial Catalog=Kentico.Community;User Id=sa;Password=Pass@12345;Persist Security Info=False;Connect Timeout=10;Encrypt=False;Current Language=English;TrustServerCertificate=True;"/>
</connectionStrings>
</configuration>
2 changes: 1 addition & 1 deletion test/Kentico.Community.Portal.Web.Tests/Tests.config
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8" ?>
<configuration>
<connectionStrings>
<add name="CMSTestConnectionString" connectionString="Data Source=localhost;Initial Catalog=Kentico.Community;Integrated Security=True;Persist Security Info=False;Connect Timeout=10;Encrypt=False;Current Language=English;"/>
<add name="CMSTestConnectionString" connectionString="Data Source=localhost;Initial Catalog=Kentico.Community;User Id=sa;Password=Pass@12345;Persist Security Info=False;Connect Timeout=10;Encrypt=False;Current Language=English;TrustServerCertificate=True;"/>
</connectionStrings>
</configuration>

0 comments on commit d6d6882

Please sign in to comment.