text: "use strict";(self.webpackChunkwebsite=self.webpackChunkwebsite||[]).push([[8515],{4137:function(e,t,r){r.d(t,{Zo:function(){return l},kt:function(){return m}});var n=r(7294);function o(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function i(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function a(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?i(Object(r),!0).forEach((function(t){o(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):i(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function u(e,t){if(null==e)return{};var r,n,o=function(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}var c=n.createContext({}),s=function(e){var t=n.useContext(c),r=t;return e&&(r="function"==typeof e?e(t):a(a({},t),e)),r},l=function(e){var t=s(e.components);return n.createElement(c.Provider,{value:t},e.children)},p={inlineCode:"code",wrapper:function(e){var t=e.children;return n.createElement(n.Fragment,{},t)}},f=n.forwardRef((function(e,t){var r=e.components,o=e.mdxType,i=e.originalType,c=e.parentName,l=u(e,["components","mdxType","originalType","parentName"]),f=s(r),m=o,b=f["".concat(c,".").concat(m)]||f[m]||p[m]||i;return r?n.createElement(b,a(a({ref:t},l),{},{components:r})):n.createElement(b,a({ref:t},l))}));function m(e,t){var r=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=r.length,a=new Array(i);a[0]=f;var u={};for(var c in t)hasOwnProperty.call(t,c)&&(u[c]=t[c]);u.originalType=e,u.mdxType="string"==typeof e?e:o,a[1]=u;for(var s=2;s<i;s++)a[s]=r[s];return n.createElement.apply(null,a)}return n.createElement.apply(null,r)}f.displayName="MDXCreateElement"},8:function(e,t,r){r.r(t),r.d(t,{frontMatter:function(){return u},contentTitle:function(){return c},metadata:function(){return s},toc:function(){return l},default:function(){return f}});var n=r(7462),o=r(3366),i=(r(7294),r(4137)),a=["components"],u={id:"githubactions",title:"Github Actions"},c=void 0,s={unversionedId:"githubactions",id:"githubactions",isDocsHomePage:!1,title:"Github Actions",description:"If your repository is hosted on Github, you can use Github Actions to run your tests on Github's infrastructure.",source:"@site/docs/GithubActions.md",sourceDirName:".",slug:"/githubactions",permalink:"/docs/githubactions",editUrl:"https://github.com/Abhi6722/hackers-hub/edit/main/website/docs/GithubActions.md",tags:[],version:"current",frontMatter:{id:"githubactions",title:"Github Actions"},sidebar:"docs",previous:{title:"Docker",permalink:"/docs/docker"},next:{title:"Jenkins",permalink:"/docs/jenkins"}},l=[],p={toc:l};function f(e){var t=e.components,r=(0,o.Z)(e,a);return(0,i.kt)("wrapper",(0,n.Z)({},p,r,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("p",null,"If your repository is hosted on Github, you can use ",(0,i.kt)("a",{parentName:"p",href:"https://docs.github.com/en/actions/getting-started-with-github-actions/about-github-actions#about-github-actions"},"Github Actions")," to run your tests on Github's infrastructure."),(0,i.kt)("ol",null,(0,i.kt)("li",{parentName:"ol"},"everytime you push changes"),(0,i.kt)("li",{parentName:"ol"},"on every pull request creation"),(0,i.kt)("li",{parentName:"ol"},"on scheduled time"),(0,i.kt)("li",{parentName:"ol"},"by manual trigger")),(0,i.kt)("p",null,"In the root of your repository, create a ",(0,i.kt)("inlineCode",{parentName:"p"},".github/workflows")," directory. Add a Yaml file, for example ",(0,i.kt)("inlineCode",{parentName:"p"},".github/workflows/ci.yaml"),". In there you will configure how to run your tests."),(0,i.kt)("p",null,"See ",(0,i.kt)("a",{parentName:"p",href:"https://github.com/webdriverio/jasmine-boilerplate/blob/master/.github/workflows/ci.yaml"},"jasmine-boilerplate")," for reference implementation, and ",(0,i.kt)("a",{parentName:"p",href:"https://github.com/webdriverio/jasmine-boilerplate/actions?query=workflow%3ACI"},"sample test runs"),"."),(0,i.kt)("pre",null,(0,i.kt)("code",{parentName:"pre",className:"language-yaml",metastring:"reference",reference:!0},"https://github.com/webdriverio/jasmine-boilerplate/blob/master/.github/workflows/ci.yaml\n")),(0,i.kt)("p",null,"Find out in the ",(0,i.kt)("a",{parentName:"p",href:"https://docs.github.com/en/actions/configuring-and-managing-workflows/configuring-a-workflow#creating-a-workflow-file"},"Github Docs")," on more information about creating workflow files."))}f.isMDXComponent=!0}}]);